Skip to content

Commit

Permalink
feat: add OS_ANDROID/OS_IOS for non-transpiled builds
Browse files Browse the repository at this point in the history
  • Loading branch information
jquick-axway authored and sgtcoolguy committed Aug 5, 2020
1 parent 32d66d3 commit b21c5d7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions common/Resources/ti.internal/extensions/globals.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,13 @@
* Licensed under the terms of the Apache Public License
* Please see the LICENSE included with this distribution for details.
*/
/* eslint-disable quote-props */
/* globals OS_ANDROID, OS_IOS */

// Add global constants.
Object.defineProperties(global, {
'OS_ANDROID': { value: OS_ANDROID, writable: false },
'OS_IOS': { value: OS_IOS, writable: false },
OS_VERSION_MAJOR: { value: Ti.Platform.versionMajor, writable: false },
OS_VERSION_MINOR: { value: Ti.Platform.versionMinor, writable: false }
});

0 comments on commit b21c5d7

Please sign in to comment.