Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-9658] BlackBerry: Add JavaScript bootstrapping to framework

GitHub Issuen/a
TypeNew Feature
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2012-07-06T08:31:35.000+0000
Affected Version/sn/a
Fix Version/sSprint 2012-09 BB, BB Preview 3
ComponentsBlackBerry
Labelsparent
ReporterDavid Lifshitz
AssigneeDavid Lifshitz
Created2012-06-20T08:37:26.000+0000
Updated2017-03-08T17:33:04.000+0000

Description

Some of the Titanium implementation can be done using JavaScript so we need to provide a way to run our own bootstrapping .js files before we load app.js. There is possibly a lot of JavaScript code we can reuse from the android directory. The method I suggest is to package the .js files into the .bar file. The files should be put into a new folder called "framework" that is next to, not inside, the "assets" folder. The "assets" and "framework" folders should be separate so we don't have conflicts. The only complication would be that the require() and include() functions might need a flag to know whether the app has been bootstrapped or not (ie read from "framework" if bootstrapping and "assets" if not). A flag may not be sufficient if things are done asynchronously so the other solution would be to check if the file calling the require/include is in "framework" or "assets" and make sure to load the file from the same directory. There should be one file called boostrap.js that will include/require the other files, as needed.

Comments

  1. Lee Morris 2017-03-08

    Closing ticket as resolved.

JSON Source