Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TIMOB-26403] Explicitly expose Alloy, _, and Backbone off the global object when it's available #913

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 10 additions & 3 deletions Alloy/template/app.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
/**
* Alloy for Titanium by Appcelerator
* This is generated code, DO NOT MODIFY - changes will be lost!
* Copyright (c) 2012 by Appcelerator, Inc.
* Copyright (c) 2012-2018 by Appcelerator, Inc.
*/
var Alloy = require('/alloy'),
var Alloy = require('/alloy');
_ = Alloy._,
Backbone = Alloy.Backbone;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why declare _ and Backbone without var?

// explicitly assign to global properties,
// don't rely on implict assignment as it is going away
if (global) {
global.Alloy = Alloy;
global._ = _;
global.Backbone = Backbone;
}

__MAPMARKER_ALLOY_JS__
Alloy.createController('index');
Alloy.createController('index');
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 9 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,20 @@
"html5",
"appc-client"
],
"version": "1.13.2",
"version": "1.13.3",
"author": "Appcelerator, Inc. <info@appcelerator.com>",
"maintainers": [
{
"name": "Tony Lukasavage",
"email": "tlukasavage@appcelerator.com"
},
{
"name": "Feon Sua",
"email": "fmiao@axway.com"
},
{
"name": "Chris Williams",
"email": "cwilliams@axway.com"
}
],
"bugs": {
Expand Down