Skip to content

Commit 5e577e4

Browse files
sebawitasis0k0
authored andcommitted
feat: update ng new/add schematics to use NativeScript 5.2 and Angular 7.2 (#191)
1 parent 9d00fb6 commit 5e577e4

File tree

3 files changed

+55
-55
lines changed

3 files changed

+55
-55
lines changed

src/add-ns/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export default function (options: MigrationOptions): Rule {
4747
addRunScriptsToPackageJson,
4848
addNativeScriptProjectId,
4949
excludeNsFilesFromTsconfig,
50-
50+
5151
options.skipAutoGeneratedComponent ?
5252
noop() :
5353
addSampleComponent(options.nsExtension, options.webExtension, options.project),
@@ -265,15 +265,15 @@ const addDependencies = () => (tree: Tree, context: SchematicContext) => {
265265

266266
// @UPGRADE: Update all versions whenever {N} version updates
267267
const depsToAdd = {
268-
'nativescript-angular': '~7.1.0',
268+
'nativescript-angular': '~7.2.0',
269269
'nativescript-theme-core': '~1.0.4',
270-
'reflect-metadata': '~0.1.8',
271-
'tns-core-modules': '~5.1.1'
270+
'reflect-metadata': '~0.1.12',
271+
'tns-core-modules': '~5.2.0'
272272
};
273273
packageJson.dependencies = Object.assign({}, depsToAdd, packageJson.dependencies);
274274

275275
const devDepsToAdd = {
276-
'nativescript-dev-webpack': '^0.18.0',
276+
'nativescript-dev-webpack': '^0.20.0',
277277
'@nativescript/schematics': '~0.4.0',
278278
};
279279
packageJson.devDependencies = Object.assign({}, devDepsToAdd, packageJson.devDependencies);
Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,35 @@
11
{
2-
"name": "<%= utils.classify(name) %>",
3-
"license": "SEE LICENSE IN <your-license-filename>",
4-
"version": "0.0.0",
5-
"nativescript": {
6-
"id": "org.nativescript.<%= utils.sanitize(name) %>"
7-
},
8-
"dependencies": {
9-
"@angular/animations": "~7.1.0",
10-
"@angular/common": "~7.1.0",
11-
"@angular/compiler": "~7.1.0",
12-
"@angular/core": "~7.1.0",
13-
"@angular/forms": "~7.1.0",
14-
"@angular/http": "~7.1.0",
15-
"@angular/platform-browser": "~7.1.0",
16-
"@angular/platform-browser-dynamic": "~7.1.0",
17-
"@angular/router": "~7.1.0",
18-
"nativescript-angular": "~7.1.0",<% if(theme) { %>
19-
"nativescript-theme-core": "~1.0.4",
20-
<% } %>"reflect-metadata": "~0.1.8",
21-
"rxjs": "~6.3.3",
22-
"tns-core-modules": "~5.1.0",
23-
"zone.js": "^0.8.26"
24-
},
25-
"devDependencies": {
26-
"@angular/cli": "^7.1.0",
27-
"@angular/compiler-cli": "~7.1.0",
28-
"@angular-devkit/core": "~7.1.0",
29-
"@nativescript/schematics": "~0.4.0",
30-
"nativescript-dev-typescript": "~0.7.0",<% if(webpack) {%>
31-
"nativescript-dev-webpack": "^0.18.0",
32-
"@ngtools/webpack": "~7.1.0",
33-
<% } %>"typescript": "~3.1.1"
34-
}
2+
"name": "<%= utils.classify(name) %>",
3+
"license": "SEE LICENSE IN <your-license-filename>",
4+
"version": "0.0.0",
5+
"nativescript": {
6+
"id": "org.nativescript.<%= utils.sanitize(name) %>"
7+
},
8+
"dependencies": {
9+
"@angular/animations": "~7.2.0",
10+
"@angular/common": "~7.2.0",
11+
"@angular/compiler": "~7.2.0",
12+
"@angular/core": "~7.2.0",
13+
"@angular/forms": "~7.2.0",
14+
"@angular/http": "~7.2.0",
15+
"@angular/platform-browser": "~7.2.0",
16+
"@angular/platform-browser-dynamic": "~7.2.0",
17+
"@angular/router": "~7.2.0",
18+
"nativescript-angular": "~7.2.0",<% if(theme) { %>
19+
"nativescript-theme-core": "~1.0.4",
20+
<% } %>"reflect-metadata": "~0.1.12",
21+
"rxjs": "~6.3.3",
22+
"tns-core-modules": "~5.2.0",
23+
"zone.js": "^0.8.26"
24+
},
25+
"devDependencies": {
26+
"@angular/cli": "^7.2.0",
27+
"@angular/compiler-cli": "~7.2.0",
28+
"@angular-devkit/core": "~7.2.0",
29+
"@nativescript/schematics": "~0.4.0",
30+
"nativescript-dev-typescript": "~0.8.0",<% if(webpack) { %>
31+
"nativescript-dev-webpack": "^0.20.0",
32+
"@ngtools/webpack": "~7.2.0",
33+
<% } %>"typescript": "~3.1.1"
34+
}
3535
}

src/ng-new/shared/_files/package.json

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -18,26 +18,26 @@
1818
},
1919
"private": true,
2020
"dependencies": {
21-
"@angular/animations": "~7.1.0",
22-
"@angular/common": "~7.1.0",
23-
"@angular/compiler": "~7.1.0",
24-
"@angular/core": "~7.1.0",
25-
"@angular/forms": "~7.1.0",
26-
"@angular/http": "~7.1.0",
27-
"@angular/platform-browser": "~7.1.0",
28-
"@angular/platform-browser-dynamic": "~7.1.0",
29-
"@angular/router": "~7.1.0",
21+
"@angular/animations": "~7.2.0",
22+
"@angular/common": "~7.2.0",
23+
"@angular/compiler": "~7.2.0",
24+
"@angular/core": "~7.2.0",
25+
"@angular/forms": "~7.2.0",
26+
"@angular/http": "~7.2.0",
27+
"@angular/platform-browser": "~7.2.0",
28+
"@angular/platform-browser-dynamic": "~7.2.0",
29+
"@angular/router": "~7.2.0",
3030
"core-js": "^2.5.4",
31-
"nativescript-angular": "~7.1.0",<% if(theme) { %>
31+
"nativescript-angular": "~7.2.0",<% if(theme) { %>
3232
"nativescript-theme-core": "~1.0.4",
33-
<% } %>"reflect-metadata": "~0.1.8",
33+
<% } %>"reflect-metadata": "~0.1.12",
3434
"rxjs": "~6.3.3",
35-
"tns-core-modules": "~5.1.1",
35+
"tns-core-modules": "~5.2.0",
3636
"zone.js": "^0.8.26"
3737
},
3838
"devDependencies": {
39-
"@angular/cli": "^7.1.0",
40-
"@angular/compiler-cli": "~7.1.0",
39+
"@angular/cli": "^7.2.0",
40+
"@angular/compiler-cli": "~7.2.0",
4141
"@angular-devkit/build-angular": "~0.11.4",
4242
"@nativescript/schematics": "~0.4.0",
4343
"@types/jasmine": "2.8.6",
@@ -51,11 +51,11 @@
5151
"karma-coverage-istanbul-reporter": "~2.0.0",
5252
"karma-jasmine": "~1.1.1",
5353
"karma-jasmine-html-reporter": "^0.2.2",
54-
"nativescript-dev-typescript": "~0.7.0",
55-
"nativescript-dev-webpack": "^0.18.0",
54+
"nativescript-dev-typescript": "~0.8.0",
55+
"nativescript-dev-webpack": "^0.20.0",
5656
"protractor": "~5.3.0",
5757
"ts-node": "~5.0.1",
5858
"tslint": "~5.9.1",
5959
"typescript": "~3.1.1"
6060
}
61-
}
61+
}

0 commit comments

Comments
 (0)