devices.json is a catalog of common web-enabled devices and their properties.
{
TYPES: [ "phones", … ],
phones: [
{
name: "LePhone",
width: 360,
height: 640,
pixelRatio: 3,
userAgent: "Mozilla/5.0 (Mobile; rv:39.0) Gecko/39.0 Firefox/39.0",
touch: true,
firefoxOS: true
}
], …
}
namebrand and model(s).widthviewport width.heightviewport height.pixelRatioratio from viewport to physical screen pixels.userAgentUA string of the device's browser.touchwhether it has a touch screen.firefoxOSwhether Firefox OS is supported.osthe OS type it usually ships with.
phones(smart phones)tabletslaptopstelevisionsconsoles(gaming consoles)watches(smart watches)
- Stable: Mozilla CDN.
- Latest: GitHub.
- Use the
check.htmlhelper. - Use
node test.jsto verify yourdevices.json. - Submit pull requests.
- Chrome Devtools: emulated_devices/module.json.
- Wikipedia: Comparison of Firefox OS devices.
- MDN: Firefox OS compatible devices.
- My Tesla Motors: Model S Web Browser Capabilities.
- Various other online sources.