MCPcopy Index your code
hub / github.com/emberjs/ember.js / createApplication

Function createApplication

tests/node/helpers/setup-app.js:90–120  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

88};
89
90function createApplication() {
91 if (this.app) return this.app;
92
93 let app = this.Ember.Application.extend().create({
94 autoboot: false,
95 Resolver: {
96 create: (specifier) => {
97 return this.registry[specifier];
98 },
99 },
100 });
101
102 let Router = this.Ember.Router.extend({
103 location: 'none',
104 });
105
106 if (this.routesCallback) {
107 Router.map(this.routesCallback);
108 }
109
110 this.register('router:main', Router);
111
112 registerApplicationClasses(app, this.registry);
113
114 // Run application initializers
115 this.run(app, 'boot');
116
117 this.app = app;
118
119 return app;
120}
121
122function register(containerKey, klass) {
123 this.registry[containerKey] = klass;

Callers

nothing calls this directly

Calls 6

runMethod · 0.80
createMethod · 0.65
mapMethod · 0.65
registerMethod · 0.65
extendMethod · 0.45

Tested by

no test coverage detected