Skip to content

Commit 3a5ddd3

Browse files
sis0k0hdeshev
authored andcommitted
chore(tsc): update to be compliant with NativeScript 3.0
1 parent 88fd1b0 commit 3a5ddd3

File tree

7 files changed

+23
-9
lines changed

7 files changed

+23
-9
lines changed

Diff for: nativescript-angular/platform-common.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import {
1919
} from "@angular/core";
2020

2121
// Work around a TS bug requiring an import of OpaqueToken without using it
22-
if (global.___TS_UNUSED) {
22+
if ((<any>global).___TS_UNUSED) {
2323
(() => {
2424
return OpaqueToken;
2525
})();
@@ -86,7 +86,7 @@ export class NativeScriptPlatformRef extends PlatformRef {
8686
}
8787

8888
private bootstrapApp() {
89-
global.__onLiveSyncCore = () => this.livesyncModule();
89+
(<any>global).__onLiveSyncCore = () => this.livesyncModule();
9090

9191
const mainPageEntry = this.createNavigationEntry(this._bootstrapper);
9292

Diff for: nativescript-angular/platform-providers.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export const DEVICE = new OpaqueToken("platfrom device");
99
export const PAGE_FACTORY = new OpaqueToken("page factory");
1010

1111
// Work around a TS bug requiring an import of platform.Device without using it
12-
if (global.___TS_UNUSED) {
12+
if ((<any>global).___TS_UNUSED) {
1313
(() => {
1414
return platform;
1515
})();

Diff for: nativescript-angular/platform.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import {
2121
} from "@angular/core";
2222

2323
// Work around a TS bug requiring an import of OpaqueToken without using it
24-
if (global.___TS_UNUSED) {
24+
if ((<any>global).___TS_UNUSED) {
2525
(() => {
2626
return OpaqueToken;
2727
})();

Diff for: nativescript-angular/tsconfig.json

+5-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,11 @@
1313
"noEmitOnError": true,
1414
"noUnusedLocals": true,
1515
"noUnusedParameters": true,
16-
"noImplicitAny": false
16+
"noImplicitAny": false,
17+
"lib": [
18+
"dom",
19+
"es6"
20+
]
1721
},
1822
"angularCompilerOptions": {
1923
"genDir": ".",

Diff for: ng-sample/tsconfig.json

+6-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,12 @@
99
"emitDecoratorMetadata": true,
1010
"noImplicitUseStrict": true,
1111
"noEmitHelpers": true,
12-
"noEmitOnError": true
12+
"noEmitOnError": true,
13+
"lib": [
14+
"es6",
15+
"dom",
16+
"es2015.iterable"
17+
]
1318
},
1419
"exclude": [
1520
"node_modules",

Diff for: tests/app/tests/test-config.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
global.mocha.setup({
1+
(<any>global).mocha.setup({
22
timeout: 20000,
33
});
44

55
import * as chai from "chai"
6-
export var assert: typeof chai.assert = global.chai.assert;
6+
export var assert: typeof chai.assert = (<any>global).chai.assert;

Diff for: tests/tsconfig.json

+6-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,12 @@
88
"emitDecoratorMetadata": true,
99
"sourceMap": false,
1010
"noEmitHelpers": true,
11-
"noEmitOnError": true
11+
"noEmitOnError": true,
12+
"lib": [
13+
"es6",
14+
"dom",
15+
"es2015.iterable"
16+
]
1217
},
1318
"exclude": [
1419
"node_modules",

0 commit comments

Comments
 (0)