Skip to content
This repository was archived by the owner on Aug 7, 2021. It is now read-only.

Commit 5a40330

Browse files
authored
feat: support for Angular 5.1 (#374)
1 parent 0aa55e4 commit 5a40330

File tree

3 files changed

+30
-25
lines changed

3 files changed

+30
-25
lines changed

Diff for: demo/AngularApp/package.json

+16-16
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@
1313
}
1414
},
1515
"dependencies": {
16-
"@angular/common": "~5.0.0",
17-
"@angular/compiler": "~5.0.0",
18-
"@angular/core": "~5.0.0",
19-
"@angular/forms": "~5.0.0",
20-
"@angular/http": "~5.0.0",
21-
"@angular/platform-browser": "~5.0.0",
22-
"@angular/platform-browser-dynamic": "~5.0.0",
23-
"@angular/router": "~5.0.0",
16+
"@angular/common": "~5.1.0",
17+
"@angular/compiler": "~5.1.0",
18+
"@angular/core": "~5.1.0",
19+
"@angular/forms": "~5.1.0",
20+
"@angular/http": "~5.1.0",
21+
"@angular/platform-browser": "~5.1.0",
22+
"@angular/platform-browser-dynamic": "~5.1.0",
23+
"@angular/router": "~5.1.0",
2424
"nativescript-angular": "next",
2525
"nativescript-theme-core": "~1.0.2",
2626
"reflect-metadata": "~0.1.8",
@@ -29,8 +29,8 @@
2929
"zone.js": "^0.8.4"
3030
},
3131
"devDependencies": {
32-
"@angular/compiler-cli": "~5.0.0",
33-
"@ngtools/webpack": "^1.8.0",
32+
"@angular/compiler-cli": "~5.1.0",
33+
"@ngtools/webpack": "~1.9.0",
3434
"@types/chai": "^4.0.2",
3535
"@types/mocha": "^2.2.41",
3636
"@types/node": "^7.0.5",
@@ -39,9 +39,9 @@
3939
"babylon": "6.18.0",
4040
"chai": "~4.1.1",
4141
"chai-as-promised": "~7.1.1",
42-
"copy-webpack-plugin": "~4.0.1",
42+
"copy-webpack-plugin": "~4.3.0",
4343
"css-loader": "~0.28.7",
44-
"extract-text-webpack-plugin": "~3.0.0",
44+
"extract-text-webpack-plugin": "~3.0.2",
4545
"lazy": "1.0.11",
4646
"mocha": "~3.5.0",
4747
"mocha-junit-reporter": "^1.13.0",
@@ -53,12 +53,12 @@
5353
"nativescript-worker-loader": "~0.8.1",
5454
"node-sass": "^4.7.1",
5555
"raw-loader": "~0.5.1",
56-
"resolve-url-loader": "~2.1.0",
56+
"resolve-url-loader": "~2.2.1",
5757
"sass-loader": "^6.0.6",
5858
"typescript": "~2.4.2",
59-
"webpack": "~3.8.1",
60-
"webpack-bundle-analyzer": "^2.8.2",
61-
"webpack-sources": "^1.0.2"
59+
"webpack": "~3.10.0",
60+
"webpack-bundle-analyzer": "^2.9.1",
61+
"webpack-sources": "^1.1.0"
6262
},
6363
"scripts": {
6464
"ns-bundle": "ns-bundle",

Diff for: dependencyManager.js

+13-8
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,15 @@ function addDependency(deps, name, version, force) {
5858

5959
function getRequiredDeps(packageJson) {
6060
const deps = {
61-
"webpack": "~3.8.1",
62-
"webpack-bundle-analyzer": "^2.8.2",
63-
"webpack-sources": "~1.0.1",
64-
"copy-webpack-plugin": "~4.0.1",
61+
"webpack": "~3.10.0",
62+
"webpack-bundle-analyzer": "^2.9.1",
63+
"webpack-sources": "~1.1.0",
64+
"copy-webpack-plugin": "~4.3.0",
6565
"raw-loader": "~0.5.1",
6666
"css-loader": "~0.28.7",
6767
"nativescript-worker-loader": "~0.8.1",
68-
"resolve-url-loader": "~2.1.0",
69-
"extract-text-webpack-plugin": "~3.0.0",
68+
"resolve-url-loader": "~2.2.1",
69+
"extract-text-webpack-plugin": "~3.0.2",
7070
};
7171

7272
if (isAngular({packageJson})) {
@@ -100,11 +100,16 @@ function resolveAngularDeps(usedDependencies) {
100100
"typescript": "~2.1.6",
101101
"@ngtools/webpack": "1.2.13",
102102
});
103-
} else {
104-
Object.assign(depsToAdd, {
103+
} else if (angularCoreVersion.startsWith("5.0")) {
104+
Object.assign(depsToAdd, {
105105
"typescript": "~2.4.2",
106106
"@ngtools/webpack": "~1.8.2",
107107
});
108+
} else {
109+
Object.assign(depsToAdd, {
110+
"typescript": "~2.4.2",
111+
"@ngtools/webpack": "~1.9.1",
112+
});
108113
}
109114

110115
return depsToAdd;

Diff for: package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
"shelljs": "^0.6.0"
4848
},
4949
"devDependencies": {
50-
"@ngtools/webpack": "^1.8.0",
50+
"@ngtools/webpack": "~1.9.0",
5151
"@types/node": "^8.0.0",
5252
"source-map-support": "^0.5.0",
5353
"typescript": "^2.6.1"

0 commit comments

Comments
 (0)