Skip to content

Commit a81c6ff

Browse files
committed
Merge pull request #71 from NativeScript/hdeshev/page-provider-fix
Fix page DI provider
2 parents 0820d71 + a06ace7 commit a81c6ff

File tree

4 files changed

+11
-27
lines changed

4 files changed

+11
-27
lines changed

ng-sample/app/app.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,17 @@ import trace = require("trace");
1313
trace.setCategories(routerTraceCategory);
1414
trace.enable();
1515

16-
//import {RendererTest} from './examples/renderer-test';
17-
//import {Benchmark} from './performance/benchmark';
18-
//import {ListTest} from './examples/list/list-test';
19-
// import {ListTestAsync} from "./examples/list/list-test-async";
20-
// import {ImageTest} from "./examples/image/image-test";
16+
import {RendererTest} from './examples/renderer-test';
17+
import {Benchmark} from './performance/benchmark';
18+
import {ListTest} from './examples/list/list-test';
19+
import {ListTestAsync} from "./examples/list/list-test-async";
20+
import {ImageTest} from "./examples/image/image-test";
2121
import {NavigationTest} from "./examples/navigation/navigation-test";
2222

2323

24-
//nativeScriptBootstrap(RendererTest);
24+
nativeScriptBootstrap(RendererTest);
2525
//nativeScriptBootstrap(Benchmark);
2626
//nativeScriptBootstrap(ListTest);
2727
// nativeScriptBootstrap(ListTestAsync);
2828
// nativeScriptBootstrap(ImageTest);
29-
nativeScriptBootstrap(NavigationTest, [NS_ROUTER_PROVIDERS]);
29+
//nativeScriptBootstrap(NavigationTest, [NS_ROUTER_PROVIDERS]);

ng-sample/hooks/before-prepare/30-remove-stale-widgets-jar.js

Lines changed: 0 additions & 16 deletions
This file was deleted.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nativescript-angular",
3-
"version": "0.0.29",
3+
"version": "0.0.30",
44
"description": "",
55
"homepage": "http://www.telerik.com",
66
"bugs": "http://www.telerik.com",

src/nativescript-angular/application.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export type ProviderArray = Array<Type | Provider | any[]>;
3434
let _platform = null;
3535

3636
export function bootstrap(appComponentType: any,
37-
customProviders: ProviderArray = null, page?: Page) : Promise<ComponentRef> {
37+
customProviders: ProviderArray = null) : Promise<ComponentRef> {
3838
NativeScriptDomAdapter.makeCurrent();
3939

4040
let nativeScriptProviders: ProviderArray = [
@@ -60,7 +60,7 @@ export function bootstrap(appComponentType: any,
6060
appProviders.push(customProviders);
6161
}
6262

63-
const pageProvider = provide(Page, {useFactory: () => page || getDefaultPage()});
63+
const pageProvider = provide(Page, {useFactory: getDefaultPage});
6464
appProviders.push(pageProvider);
6565

6666
if (!_platform) {
@@ -93,7 +93,7 @@ export function nativeScriptBootstrap(appComponentType: any, customProviders?: P
9393

9494
//profiling.start('ng-bootstrap');
9595
console.log('BOOTSTRAPPING...');
96-
bootstrap(appComponentType, customProviders, page).then((appRef) => {
96+
bootstrap(appComponentType, customProviders).then((appRef) => {
9797
//profiling.stop('ng-bootstrap');
9898
console.log('ANGULAR BOOTSTRAP DONE.');
9999
}, (err) =>{

0 commit comments

Comments
 (0)