Skip to content

Commit 7edfa6b

Browse files
committed
fix(ts): ship package with reference to iterable interface
1 parent 64fdd36 commit 7edfa6b

11 files changed

+25
-11
lines changed

Diff for: .gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ tags
99
/nativescript-angular/**/*.d.ts
1010
/nativescript-angular/**/*.js
1111

12+
!/nativescript-angular/iterable.d.ts
1213
!/nativescript-angular/global.d.ts
1314
!/nativescript-angular/postinstall.js
1415
!/nativescript-angular/hooks/**/*.js
@@ -52,4 +53,4 @@ startup-test/node_modules
5253
!.vscode/settings.json
5354
!.vscode/tasks.json
5455
!.vscode/launch.json
55-
!.vscode/extensions.json
56+
!.vscode/extensions.json

Diff for: nativescript-angular/.npmignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55

66
*.js.map
77

8-
tsconfig.json
98
global.d.ts
9+
tsconfig.json
1010
.npmignore
1111
gulpfile.js
1212
tslint.json

Diff for: nativescript-angular/iterable.d.ts

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
declare interface Iterable<T> {}

Diff for: nativescript-angular/nativescript.module.ts

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
/// <reference path="./iterable.d.ts" />
2+
13
import "globals";
24
import "./zone-js/dist/zone-nativescript";
35

Diff for: nativescript-angular/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"noUnusedLocals": true,
1515
"noUnusedParameters": true,
1616
"noImplicitAny": false
17-
},
17+
},
1818
"angularCompilerOptions": {
1919
"genDir": ".",
2020
"skipMetadataEmit": false,

Diff for: nativescript-angular/view-util.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,8 @@ export class ViewUtil {
210210

211211
let index = 0;
212212
let found = false;
213-
parent.eachChild(child => {
213+
214+
parent._eachLayoutView(child => {
214215
if (child === node) {
215216
found = true;
216217
}

Diff for: ng-sample/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
},
2424
"homepage": "https://github.com/NativeScript/template-hello-world",
2525
"dependencies": {
26-
"tns-core-modules": "~2.5.0",
2726
"@angular/common": "4.0.0-rc.3",
2827
"@angular/compiler": "4.0.0-rc.3",
2928
"@angular/core": "4.0.0-rc.3",
@@ -33,7 +32,8 @@
3332
"@angular/platform-browser-dynamic": "4.0.0-rc.3",
3433
"@angular/router": "4.0.0-rc.3",
3534
"nativescript-angular": "file:../nativescript-angular",
36-
"rxjs": "~5.0.1"
35+
"rxjs": "~5.0.1",
36+
"tns-core-modules": "~2.5.0"
3737
},
3838
"devDependencies": {
3939
"zone.js": "~0.7.2",
@@ -50,7 +50,7 @@
5050
"nativescript": {
5151
"id": "org.nativescript.ngsample",
5252
"tns-android": {
53-
"version": "2.4.1"
53+
"version": "2.5.0"
5454
},
5555
"tns-ios": {
5656
"version": "2.4.0"

Diff for: ng-sample/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@
1515
"node_modules",
1616
"platforms"
1717
]
18-
}
18+
}

Diff for: tests/package.json

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
{
2+
"nativescript": {
3+
"id": "org.nativescript.ngtests",
4+
"tns-android": {
5+
"version": "2.5.0"
6+
},
7+
"tns-ios": {
8+
"version": "2.5.0"
9+
}
110
},
211
"name": "ngtests",
312
"main": "app.js",
@@ -48,7 +57,7 @@
4857
"nativescript-dev-typescript": "^0.3.1",
4958
"socket.io": "1.4.8",
5059
"socket.io-client": "1.4.8",
51-
"typescript": "~2.2.0",
60+
"typescript": "~2.1.0",
5261
"wd": "0.4.0",
5362
"zone.js": "^0.7.2"
5463
},

Diff for: tests/references.d.ts

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/// <reference path="./node_modules/tns-core-modules/tns-core-modules.d.ts" /> Needed for autocompletion and compilation.

Diff for: tests/tsconfig.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
"target": "es5",
55
"experimentalDecorators": true,
66
"emitDecoratorMetadata": true,
7-
"sourceMap": false,
87
"noEmitHelpers": true,
98
"noEmitOnError": true
109
},
@@ -13,4 +12,4 @@
1312
"platforms",
1413
"**/*.aot"
1514
]
16-
}
15+
}

0 commit comments

Comments
 (0)