JSPM

  • Created
  • Published
  • Downloads 180
  • Score
    100M100P100Q58939F
  • License MIT

Mobile Device Spec detection.

Package Exports

  • uupaa.spec.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (uupaa.spec.js) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Spec.js Build Status

npm

Mobile Device Spec detection.

This module made of WebModule.

Documentation

Browser, NW.js and Electron

<script src="<module-dir>/lib/WebModule.js"></script>
<script src="<module-dir>/lib/WebGLDetector.js"></script>
<script src="<module-dir>/lib/UserAgent.js"></script>
<script src="<module-dir>/lib/SpecCatalog.js"></script>
<script src="<module-dir>/lib/Spec.js"></script>
<script>

var ua = new UserAgent(); // iPhone 6
var spec = new Spec(ua);

spec.UNKNOWN            // -> false
spec.SOC                // -> "A8"
spec.GPU                // -> "POWERVR GX6450",
spec.RAM                // -> 1024
spec.BLE                // -> true
spec.NFC                // -> false
spec.ATOM               // -> false
spec.SIMD               // -> true
spec.FORCE_TOUCH        // -> false
spec.FORCE_CLICK        // -> false
spec.MAX_THREADS        // -> 2
spec.MAX_TOUCH_POINTS   // -> 5
spec.MAX_TEXTURE_SIZE   // -> 16384
spec.LOW_END            // -> false
spec.OUTMODED           // -> false

</script>

WebWorkers

importScripts("<module-dir>lib/WebModule.js");
importScripts("<module-dir>lib/SpecCatalog.js");
importScripts("<module-dir>lib/Spec.js");

Node.js

require("<module-dir>lib/WebModule.js");
require("<module-dir>lib/SpecCatalog.js");
require("<module-dir>lib/Spec.js");