Searchable collection of Apple devices
npm install ios-device-list
$ npm install ios-device-list
`
Usage
In node:
`js
var iosDevices = require('ios-device-list');
`
In browser:
`html
`
$3
Returns the device type list: airpods, apple_tv, apple_watch, homepod, ipad, ipad_air, ipad_pro, ipad_mini, iphone, ipod_touch
$3
Returns the full device list.
With optional type parameter returns the device list of the actual type.
$3
Returns the full Generation list.
With optional type parameter returns the generation list of the actual type.
$3
Returns the full "A" Number list.
With optional type parameter returns the "A" Number list of the actual type.
$3
Returns the full FCC ID list.
With optional type parameter returns the FCC ID list of the actual type.
$3
Returns the full Internal Name list.
With optional type parameter returns the Internal Name list of the actual type.
$3
Returns the full Identifier list.
With optional type parameter returns the Identifier list of the actual type.
$3
Returns the full Color list.
With optional type parameter returns the Color list of the actual type.
$3
Returns the full Storage list.
With optional type parameter returns the Storage list of the actual type.
$3
Returns the full Model list.
With optional type parameter returns the Model list of the actual type.
$3
Returns a device list with matching Generation.
With optional type parameter the result is filtered by the device type.
options is an Object.
- caseInsensitive: boolean (default false) - do not care of case type
- contains: boolean (default false) - return partial (substring) results too
$3
Returns a device list with matching "A" Number.
With optional type parameter the result is filtered by the device type.
$3
Returns a device list with matching FCC ID.
With optional type parameter the result is filtered by the device type.
$3
Returns a device list with matching Internal Name.
With optional type parameter the result is filtered by the device type.
$3
Returns a device list with matching Identifier.
With optional type parameter the result is filtered by the device type.
$3
Returns a device list with matching Color.
With optional type parameter the result is filtered by the device type.
$3
Returns a device list with matching Storage.
With optional type parameter the result is filtered by the device type.
$3
Returns a device list with matching Model.
With optional type parameter the result is filtered by the device type.
$3
Returns the generation name with matching Identifier.
With optional type parameter the result is filtered by the device type.
Example
`js
var iosDevices = require('ios-device-list');
var deviceTypes = iosDevices.deviceTypes();
var devices = iosDevices.devices();
console.log(deviceTypes.length);
// 6
console.log(devices.length);
// 727
console.log(devices[500]);
// { Type: 'iphone',
// Generation: 'iPhone 5c',
// ANumber: [ 'A1456', 'A1532' ],
// Bootrom: [ 'Bootrom 1145.3' ],
// Variant: 'iPhone5,3',
// FCCID: [ 'BCG‑E2644A' ],
// InternalName: 'N48AP',
// Identifier: 'iPhone5,3',
// Color: 'Yellow',
// Storage: '32 GB',
// Model: 'MF135' }
var iphone82;
iphone82 = iosDevices.deviceByIdentifier('iPhone8,2');
console.log(iphone82.length);
// 24
iphone82 = iosDevices.deviceByIdentifier('iphone8,2', null, { caseInsensitive: true });
console.log(iphone82.length);
// 24
iphone82 = iosDevices.deviceByIdentifier('iPhone8', null, { contains: true });
console.log(iphone82.length);
// 56
var gen = iosDevices.generationByIdentifier('iPhone8,2');
console.log(gen);
// 'iPhone 6s Plus'
``