titanium-platforms
v1.0.0
Published
Titanium™ SDK utils for device conditional code
Downloads
5
Maintainers
Readme
titanium-platforms
Titanium™ SDK utils for device conditional code.
Usage
To be used only with Titaniumifier in both package mode and in app mode.
If you’re using Alloy just use one of the built-in OS_*
constants.
Install
$ npm install --save titanium-platforms
ECMAScript 5
var OS_ANDROID = require('titanium-platforms/os/android');
var OS_IOS = require('titanium-platforms/os/ios');
var OS_MOBILEWEB = require('titanium-platforms/os/mobileweb');
var OS_WINDOWS = require('titanium-platforms/os/windows');
ECMAScript 2015 (aka ES6)
To be used with Babel pre-compilation, for example.
import OS_ANDROID from 'titanium-platforms/os/android';
import OS_IOS from 'titanium-platforms/os/ios';
import OS_MOBILEWEB from 'titanium-platforms/os/mobileweb';
import OS_WINDOWS from 'titanium-platforms/os/windows';
License
MIT