[ALOY-1074] Enable developers to specify Backbone version in config.json
|Fix Version/s||Alloy 1.6.0|
|Assignee||Feon Sua Xin Miao|
DescriptionEnable developers to choose whether to use Backbone 0.9x or 1.x. The default should be 1.x. Support for the older version would be to provide backward compatibility for existing projects that depend on 0.9x behaviors or functionality.
- Feon Sua Xin Miao 2014-09-15
PR : https://github.com/appcelerator/alloy/pull/561
1. Create an app, specify backbone version in config.json,
"backbone": "0.9.2"2. Compile the app, i.e. android and in project dir type:
The correct backbone version should be shown.
3. Existing sample apps under
// Backbone.js 0.9.2
test/apps/models/*should run without error. 4.
test/apps/models/bindings_listviewshould run without error on backbone v1.1.2 5. For
test/models/todoto run properly on backbone 1.1.2, uncomment the code in model JS that override collection's fetch method Note: default backbone version is 0.9.2
- Tim Poulsen 2014-09-15 Using backbone 1.1.2, the models/todo app does not work properly. I cannot add a new to do task, marking an item as completed throws an "undefined is not and object (evaluating todo.set)" error.
- Tim Poulsen 2014-09-23
For QE test:
1. Run any of the test/apps/models/* test apps. All should run without error
2. Run the models/binding_listview app and then enter the
headcommand described in Feon's comment above; it should show backbone version 0.9.2. 3. Edit test/apps/models/binding_listview/config.json to add a new key:
"backbone": "1.1.2". Edit test/apps/models/binding_listview/models/info.js and uncomment the block as described in the comments in that file. Build and run the app and it should run properly without errors. 4. Run the
headcommand again to confirm that the app was built using backbone 1.1.2.
- Tim Poulsen 2014-10-23 Reopen to backport to 1_6_X branch
- Feon Sua Xin Miao 2014-10-24 1_6_X: https://github.com/appcelerator/alloy/pull/598
- Tim Poulsen 2014-10-24 Works! PR merged.
- Eric Wieber 2015-03-25
Verified fixed using:
Titanium SDK 4.0.0.v20150323131014
Appc NPM: 0.3.34
Appc CLI 0.2.187
You can correctly set the backbone version in
config.js. However, 1.X is not the default.