2
2
import { NativeScriptModule , platformNativeScriptDynamic } from "nativescript-angular/platform" ;
3
3
import { NativeScriptRouterModule } from "nativescript-angular/router" ;
4
4
import { NativeScriptFormsModule } from "nativescript-angular/forms" ;
5
- import { AppComponent } from "./app.component" ;
6
- import { GestureComponent } from "./snippets/gestures.component" ;
7
- import { LayoutsComponent } from "./snippets/layouts.component" ;
8
- import { IconFontComponent } from "./snippets/icon-font.component" ;
9
- import { APP_ROOT_VIEW } from "nativescript-angular/platform-providers" ;
10
- import { Page } from "ui/page" ;
11
- import { StackLayout } from "ui/layouts/stack-layout" ;
5
+ import { AppComponent } from "./app.component" ;
6
+ import { GestureComponent } from "./snippets/gestures.component" ;
7
+ import { LayoutsComponent } from "./snippets/layouts.component" ;
8
+ import { IconFontComponent } from "./snippets/icon-font.component" ;
9
+ import { APP_ROOT_VIEW } from "nativescript-angular/platform-providers" ;
10
+ import { Page } from "ui/page" ;
11
+ import { StackLayout } from "ui/layouts/stack-layout" ;
12
12
13
13
import * as application from "application" ;
14
14
import "ui/styling/style" ;
15
15
import "ui/frame" ;
16
- import { HOOKS_LOG } from "./base.component" ;
17
- import { MultiPageMain , routes as multiPageRoutes } from "./multi-page-main.component" ;
18
- import { SinglePageMain , routes as singlePageRoutes } from "./single-page-main.component" ;
19
- import { LazyLoadMain , routes as lazyLoadRoutes } from "./lazy-load-main" ;
20
- import { FirstComponent } from "./first.component" ;
21
- import { SecondComponent } from "./second.component" ;
16
+ import { HOOKS_LOG } from "./base.component" ;
17
+ import { MultiPageMain , routes as multiPageRoutes } from "./multi-page-main.component" ;
18
+ import { SinglePageMain , routes as singlePageRoutes } from "./single-page-main.component" ;
19
+ import { LazyLoadMain , routes as lazyLoadRoutes } from "./lazy-load-main" ;
20
+ import { FirstComponent } from "./first.component" ;
21
+ import { SecondComponent } from "./second.component" ;
22
22
import { OpaqueToken , NgModule } from "@angular/core" ;
23
23
24
- import { PageNavigationApp } from "./snippets/navigation/page-outlet" ;
25
- import { NavigationApp } from "./snippets/navigation/router-outlet" ;
24
+ import { PageNavigationApp } from "./snippets/navigation/page-outlet" ;
25
+ import { NavigationApp } from "./snippets/navigation/router-outlet" ;
26
26
27
27
import { rendererTraceCategory , routerTraceCategory } from "nativescript-angular/trace" ;
28
28
29
- import { BehaviorSubject } from "rxjs" ;
29
+ import { BehaviorSubject } from "rxjs" ;
30
30
31
31
import trace = require( "trace" ) ;
32
32
// trace.setCategories(rendererTraceCategory + "," + routerTraceCategory);
@@ -36,15 +36,15 @@ trace.enable();
36
36
// nativeScriptBootstrap(GestureComponent);
37
37
// nativeScriptBootstrap(LayoutsComponent);
38
38
// nativeScriptBootstrap(IconFontComponent);
39
- const platform = platformNativeScriptDynamic ( { bootInExistingPage : true } ) ;
39
+ const platform = platformNativeScriptDynamic ( { bootInExistingPage : true } ) ;
40
40
const root = new StackLayout ( ) ;
41
- const rootViewProvider = { provide : APP_ROOT_VIEW , useValue : root } ;
41
+ const rootViewProvider = { provide : APP_ROOT_VIEW , useValue : root } ;
42
42
const singlePageHooksLog = new BehaviorSubject ( [ ] ) ;
43
- const singlePageHooksLogProvider = { provide : HOOKS_LOG , useValue : singlePageHooksLog } ;
43
+ const singlePageHooksLogProvider = { provide : HOOKS_LOG , useValue : singlePageHooksLog } ;
44
44
const multiPageHooksLog = new BehaviorSubject ( [ ] ) ;
45
- const multiPageHooksLogProvider = { provide : HOOKS_LOG , useValue : multiPageHooksLog } ;
45
+ const multiPageHooksLogProvider = { provide : HOOKS_LOG , useValue : multiPageHooksLog } ;
46
46
const lazyLoadHooksLog = new BehaviorSubject ( [ ] ) ;
47
- const lazyLoadHooksLogProvider = { provide : HOOKS_LOG , useValue : lazyLoadHooksLog } ;
47
+ const lazyLoadHooksLogProvider = { provide : HOOKS_LOG , useValue : lazyLoadHooksLog } ;
48
48
49
49
@NgModule ( {
50
50
bootstrap : [
@@ -76,7 +76,7 @@ const lazyLoadHooksLogProvider = {provide: HOOKS_LOG, useValue: lazyLoadHooksLog
76
76
singlePageHooksLogProvider ,
77
77
]
78
78
} )
79
- class SinglePageModule { }
79
+ class SinglePageModule { }
80
80
81
81
@NgModule ( {
82
82
bootstrap : [
@@ -108,7 +108,7 @@ class SinglePageModule {}
108
108
multiPageHooksLogProvider ,
109
109
]
110
110
} )
111
- class MultiPageModule { }
111
+ class MultiPageModule { }
112
112
113
113
@NgModule ( {
114
114
bootstrap : [
@@ -137,14 +137,14 @@ class MultiPageModule {}
137
137
lazyLoadHooksLogProvider ,
138
138
]
139
139
} )
140
- class LazyLoadModule { }
140
+ class LazyLoadModule { }
141
141
142
142
application . start ( {
143
143
create : ( ) : Page => {
144
144
const page = new Page ( ) ;
145
145
page . content = root ;
146
146
147
- let onLoadedHandler = function ( args ) {
147
+ let onLoadedHandler = function ( args ) {
148
148
page . off ( 'loaded' , onLoadedHandler ) ;
149
149
//profiling.stop('application-start');
150
150
console . log ( 'Page loaded' ) ;
0 commit comments