@schematics/angular 20.0.0-rc.3 → 20.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"replace-provide-server-routing": {
|
|
9
9
|
"version": "20.0.0",
|
|
10
10
|
"factory": "./replace-provide-server-routing/migration",
|
|
11
|
-
"description": "Migrate 'provideServerRendering' to use 'withRoutes' and remove 'provideServerRouting' from '@angular/ssr'."
|
|
11
|
+
"description": "Migrate 'provideServerRendering' to use 'withRoutes', and remove 'provideServerRouting' and 'provideServerRoutesConfig' from '@angular/ssr'."
|
|
12
12
|
},
|
|
13
13
|
"update-module-resolution": {
|
|
14
14
|
"version": "20.0.0",
|
|
@@ -49,7 +49,9 @@ function* visit(directory) {
|
|
|
49
49
|
const entry = directory.file(path);
|
|
50
50
|
if (entry) {
|
|
51
51
|
const content = entry.content;
|
|
52
|
-
if (content.includes('provideServerRouting')
|
|
52
|
+
if ((content.includes('provideServerRouting') ||
|
|
53
|
+
content.includes('provideServerRoutesConfig')) &&
|
|
54
|
+
content.includes('@angular/ssr')) {
|
|
53
55
|
// Only need to rename the import so we can just string replacements.
|
|
54
56
|
yield [entry.path, content.toString()];
|
|
55
57
|
}
|
|
@@ -86,7 +88,8 @@ function default_1() {
|
|
|
86
88
|
.map((el) => {
|
|
87
89
|
if (ts.isCallExpression(el) &&
|
|
88
90
|
ts.isIdentifier(el.expression) &&
|
|
89
|
-
el.expression.text === 'provideServerRouting'
|
|
91
|
+
(el.expression.text === 'provideServerRouting' ||
|
|
92
|
+
el.expression.text === 'provideServerRoutesConfig')) {
|
|
90
93
|
const [withRouteVal, ...others] = el.arguments.map((arg) => arg.getText());
|
|
91
94
|
return `provideServerRendering(withRoutes(${withRouteVal})${others.length ? ', ' + others.join(', ') : ''})`;
|
|
92
95
|
}
|
|
@@ -110,7 +113,7 @@ function default_1() {
|
|
|
110
113
|
const elements = namedBindings.elements;
|
|
111
114
|
const updatedElements = elements
|
|
112
115
|
.map((el) => el.getText())
|
|
113
|
-
.filter((x) => x !== 'provideServerRouting');
|
|
116
|
+
.filter((x) => x !== 'provideServerRouting' && x !== 'provideServerRoutesConfig');
|
|
114
117
|
updatedElements.push('withRoutes');
|
|
115
118
|
recorder.remove(namedBindings.getStart(), namedBindings.getWidth());
|
|
116
119
|
recorder.insertLeft(namedBindings.getStart(), `{ ${updatedElements.sort().join(', ')} }`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@schematics/angular",
|
|
3
|
-
"version": "20.0.0
|
|
3
|
+
"version": "20.0.0",
|
|
4
4
|
"description": "Schematics specific to Angular",
|
|
5
5
|
"homepage": "https://github.com/angular/angular-cli",
|
|
6
6
|
"keywords": [
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
},
|
|
23
23
|
"schematics": "./collection.json",
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@angular-devkit/core": "20.0.0
|
|
26
|
-
"@angular-devkit/schematics": "20.0.0
|
|
25
|
+
"@angular-devkit/core": "20.0.0",
|
|
26
|
+
"@angular-devkit/schematics": "20.0.0",
|
|
27
27
|
"jsonc-parser": "3.3.1"
|
|
28
28
|
},
|
|
29
29
|
"repository": {
|
|
@@ -14,9 +14,9 @@ const dependencies = require('./latest-versions/package.json')['dependencies'];
|
|
|
14
14
|
exports.latestVersions = {
|
|
15
15
|
...dependencies,
|
|
16
16
|
// As Angular CLI works with same minor versions of Angular Framework, a tilde match for the current
|
|
17
|
-
Angular: '^20.0.0
|
|
18
|
-
NgPackagr: '^20.0.0
|
|
19
|
-
DevkitBuildAngular: '^20.0.0
|
|
20
|
-
AngularBuild: '^20.0.0
|
|
21
|
-
AngularSSR: '^20.0.0
|
|
17
|
+
Angular: '^20.0.0',
|
|
18
|
+
NgPackagr: '^20.0.0',
|
|
19
|
+
DevkitBuildAngular: '^20.0.0',
|
|
20
|
+
AngularBuild: '^20.0.0',
|
|
21
|
+
AngularSSR: '^20.0.0',
|
|
22
22
|
};
|