File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ import EmberApp from ' ember-strict-application-resolver' ;
2+ import EmberRouter from ' @ember/routing/router' ;
3+ import PageTitleService from ' ember-page-title/services/page-title' ;
4+
5+ class Router extends EmberRouter {
6+ location = ' history' ;
7+ rootURL = ' /' ;
8+ }
9+
10+ export class App extends EmberApp {
11+ /**
12+ * Any services or anything from the addon that needs to be in the app-tree registry
13+ * will need to be manually specified here.
14+ *
15+ * Techniques to avoid needing this:
16+ * - private services
17+ * - require the consuming app import and configure themselves
18+ * (which is what we're emulating here)
19+ */
20+ modules = {
21+ ' ./router' : Router ,
22+ ' ./services/page-title' : PageTitleService ,
23+ /**
24+ * NOTE: this glob will import everything matching the glob,
25+ * and includes non-services in the services directory.
26+ */
27+ ... import .meta .glob (' ./services/**/*' , { eager: true }),
28+ ... import .meta .glob (' ./templates/**/*' , { eager: true }),
29+ };
30+ }
31+
32+ Router .map (function () { });
File renamed without changes.
File renamed without changes.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ import EmberApp from 'ember-strict-application-resolver';
12import EmberRouter from '@ember/routing/router';
23import * as QUnit from 'qunit';
34import { setApplication } from '@ember/test-helpers';
45import { setup } from 'qunit-dom';
56import { start as qunitStart, setupEmberOnerrorValidation } from 'ember-qunit';
67
7- import { App, docsAppRegistry } from '#dosc-app/app';
8-
98class Router extends EmberRouter {
109 location = 'none';
1110 rootURL = '/';
1211}
1312
14- class TestApp extends App {
13+ class TestApp extends EmberApp {
1514 modules = {
16- ...docsAppRegistry,
17- './router': Router,
18- // add any overrides here
15+ './router': { default: Router },
16+ // add any custom services here
1917 // import.meta.glob('./services/*', { eager: true }),
2018 };
2119}
You can’t perform that action at this time.
0 commit comments