domReadyprivate
This is the autoboot flow:
- Boot the app by calling
this.boot()
- Create an instance (or use the
__deprecatedInstance__
in globals mode) - Boot the instance by calling
instance.boot()
- Invoke the
App.ready()
callback - Kick-off routing on the instance
Ideally, this is all we would need to do:
_autoBoot() { this.boot().then(() => { let instance = (this._globalsMode) ? this.__deprecatedInstance__ : this.buildInstance(); return instance.boot(); }).then((instance) => { App.ready(); instance.startRouting(); }); }
Unfortunately, we cannot actually write this because we need to participate in the "synchronous" boot process. While the code above would work fine on the initial boot (i.e. DOM ready), when App.reset()
is called, we need to boot a new instance synchronously (see the documentation on _bootSync()
for details).
Because of this restriction, the actual logic of this method is located inside didBecomeReady()
.
Please login to continue.