@nx/angular 21.5.0-beta.0 → 21.5.0-beta.2
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.
- package/migrations.json +169 -0
- package/package.json +9 -9
- package/spec/src/migrations/update-21-5-0/remove-default-karma-configuration-files.spec.d.ts +2 -0
- package/spec/src/migrations/update-21-5-0/remove-default-karma-configuration-files.spec.d.ts.map +1 -0
- package/spec/src/migrations/update-21-5-0/update-angular-cli.spec.d.ts +2 -0
- package/spec/src/migrations/update-21-5-0/update-angular-cli.spec.d.ts.map +1 -0
- package/src/builders/dev-server/dev-server.impl.d.ts.map +1 -1
- package/src/builders/dev-server/dev-server.impl.js +2 -1
- package/src/builders/webpack-browser/webpack-browser.impl.d.ts.map +1 -1
- package/src/builders/webpack-browser/webpack-browser.impl.js +16 -0
- package/src/builders/webpack-server/webpack-server.impl.d.ts.map +1 -1
- package/src/builders/webpack-server/webpack-server.impl.js +16 -0
- package/src/executors/module-federation-dev-server/module-federation-dev-server.impl.d.ts.map +1 -1
- package/src/executors/module-federation-dev-server/module-federation-dev-server.impl.js +16 -0
- package/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.d.ts.map +1 -1
- package/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.js +16 -0
- package/src/generators/convert-to-rspack/convert-to-rspack.d.ts.map +1 -1
- package/src/generators/convert-to-rspack/convert-to-rspack.js +9 -3
- package/src/generators/setup-mf/lib/fix-bootstrap.js +2 -2
- package/src/generators/utils/version-utils.d.ts +5 -0
- package/src/generators/utils/version-utils.d.ts.map +1 -1
- package/src/generators/utils/version-utils.js +18 -0
- package/src/migrations/update-21-5-0/remove-default-karma-configuration-files.d.ts +3 -0
- package/src/migrations/update-21-5-0/remove-default-karma-configuration-files.d.ts.map +1 -0
- package/src/migrations/update-21-5-0/remove-default-karma-configuration-files.js +53 -0
- package/src/migrations/update-21-5-0/set-tsconfig-option.d.ts.map +1 -1
- package/src/migrations/update-21-5-0/set-tsconfig-option.js +5 -1
- package/src/migrations/update-21-5-0/update-angular-cli.d.ts +4 -0
- package/src/migrations/update-21-5-0/update-angular-cli.d.ts.map +1 -0
- package/src/migrations/update-21-5-0/update-angular-cli.js +23 -0
- package/src/migrations/update-21-5-0/utils/karma-config-analyzer.d.ts +28 -0
- package/src/migrations/update-21-5-0/utils/karma-config-analyzer.d.ts.map +1 -0
- package/src/migrations/update-21-5-0/utils/karma-config-analyzer.js +139 -0
- package/src/migrations/update-21-5-0/utils/karma-config-comparer.d.ts +64 -0
- package/src/migrations/update-21-5-0/utils/karma-config-comparer.d.ts.map +1 -0
- package/src/migrations/update-21-5-0/utils/karma-config-comparer.js +145 -0
- package/src/utils/backward-compatible-versions.d.ts +1 -1
- package/src/utils/backward-compatible-versions.d.ts.map +1 -1
- package/src/utils/backward-compatible-versions.js +0 -1
- package/src/utils/versions.d.ts +4 -5
- package/src/utils/versions.d.ts.map +1 -1
- package/src/utils/versions.js +5 -6
package/migrations.json
CHANGED
@@ -357,6 +357,23 @@
|
|
357
357
|
"version": "21.5.0-beta.0",
|
358
358
|
"description": "Set the 'tsConfig' option to build and test targets to help with Angular migration issues.",
|
359
359
|
"factory": "./src/migrations/update-21-5-0/set-tsconfig-option"
|
360
|
+
},
|
361
|
+
"update-angular-cli-version-20-2-0": {
|
362
|
+
"cli": "nx",
|
363
|
+
"version": "21.5.0-beta.2",
|
364
|
+
"requires": {
|
365
|
+
"@angular/core": ">=20.2.0"
|
366
|
+
},
|
367
|
+
"description": "Update the @angular/cli package version to ~20.2.0.",
|
368
|
+
"factory": "./src/migrations/update-21-5-0/update-angular-cli"
|
369
|
+
},
|
370
|
+
"remove-default-karma-configuration-files": {
|
371
|
+
"version": "21.5.0-beta.2",
|
372
|
+
"requires": {
|
373
|
+
"@angular/core": ">=20.2.0"
|
374
|
+
},
|
375
|
+
"description": "Remove any Karma configuration files that only contain the default content. The default configuration is automatically available without a specific project configurationfile.",
|
376
|
+
"factory": "./src/migrations/update-21-5-0/remove-default-karma-configuration-files"
|
360
377
|
}
|
361
378
|
},
|
362
379
|
"packageJsonUpdates": {
|
@@ -1915,6 +1932,158 @@
|
|
1915
1932
|
"alwaysAddToPackageJson": false
|
1916
1933
|
}
|
1917
1934
|
}
|
1935
|
+
},
|
1936
|
+
"21.5.0": {
|
1937
|
+
"version": "21.5.0-beta.2",
|
1938
|
+
"x-prompt": "Do you want to update the Angular version to v20.2?",
|
1939
|
+
"requires": {
|
1940
|
+
"@angular/core": ">=20.1.0 <20.2.0"
|
1941
|
+
},
|
1942
|
+
"packages": {
|
1943
|
+
"@angular-devkit/build-angular": {
|
1944
|
+
"version": "~20.2.0",
|
1945
|
+
"alwaysAddToPackageJson": false
|
1946
|
+
},
|
1947
|
+
"@angular-devkit/core": {
|
1948
|
+
"version": "~20.2.0",
|
1949
|
+
"alwaysAddToPackageJson": false
|
1950
|
+
},
|
1951
|
+
"@angular-devkit/schematics": {
|
1952
|
+
"version": "~20.2.0",
|
1953
|
+
"alwaysAddToPackageJson": false
|
1954
|
+
},
|
1955
|
+
"@angular/build": {
|
1956
|
+
"version": "~20.2.0",
|
1957
|
+
"alwaysAddToPackageJson": false
|
1958
|
+
},
|
1959
|
+
"@angular/pwa": {
|
1960
|
+
"version": "~20.2.0",
|
1961
|
+
"alwaysAddToPackageJson": false
|
1962
|
+
},
|
1963
|
+
"@angular/ssr": {
|
1964
|
+
"version": "~20.2.0",
|
1965
|
+
"alwaysAddToPackageJson": false
|
1966
|
+
},
|
1967
|
+
"@schematics/angular": {
|
1968
|
+
"version": "~20.2.0",
|
1969
|
+
"alwaysAddToPackageJson": false
|
1970
|
+
},
|
1971
|
+
"@angular-devkit/architect": {
|
1972
|
+
"version": "~0.2002.0",
|
1973
|
+
"alwaysAddToPackageJson": false
|
1974
|
+
},
|
1975
|
+
"@angular-devkit/build-webpack": {
|
1976
|
+
"version": "~0.2002.0",
|
1977
|
+
"alwaysAddToPackageJson": false
|
1978
|
+
},
|
1979
|
+
"@angular/core": {
|
1980
|
+
"version": "~20.2.0",
|
1981
|
+
"alwaysAddToPackageJson": true
|
1982
|
+
},
|
1983
|
+
"@angular/material": {
|
1984
|
+
"version": "~20.2.0",
|
1985
|
+
"alwaysAddToPackageJson": false
|
1986
|
+
},
|
1987
|
+
"@angular/cdk": {
|
1988
|
+
"version": "~20.2.0",
|
1989
|
+
"alwaysAddToPackageJson": false
|
1990
|
+
},
|
1991
|
+
"@angular/google-maps": {
|
1992
|
+
"version": "~20.2.0",
|
1993
|
+
"alwaysAddToPackageJson": false
|
1994
|
+
},
|
1995
|
+
"ng-packagr": {
|
1996
|
+
"version": "~20.2.0",
|
1997
|
+
"alwaysAddToPackageJson": false
|
1998
|
+
}
|
1999
|
+
}
|
2000
|
+
},
|
2001
|
+
"21.5.0-angular-eslint": {
|
2002
|
+
"version": "21.5.0-beta.2",
|
2003
|
+
"requires": {
|
2004
|
+
"@angular/core": ">= 20.0.0 < 21.0.0",
|
2005
|
+
"typescript-eslint": "^8.0.0",
|
2006
|
+
"eslint": "^8.57.0 || ^9.0.0"
|
2007
|
+
},
|
2008
|
+
"packages": {
|
2009
|
+
"angular-eslint": {
|
2010
|
+
"version": "^20.2.0",
|
2011
|
+
"alwaysAddToPackageJson": false
|
2012
|
+
},
|
2013
|
+
"@angular-eslint/eslint-plugin": {
|
2014
|
+
"version": "^20.2.0",
|
2015
|
+
"alwaysAddToPackageJson": false
|
2016
|
+
},
|
2017
|
+
"@angular-eslint/eslint-plugin-template": {
|
2018
|
+
"version": "^20.2.0",
|
2019
|
+
"alwaysAddToPackageJson": false
|
2020
|
+
},
|
2021
|
+
"@angular-eslint/template-parser": {
|
2022
|
+
"version": "^20.2.0",
|
2023
|
+
"alwaysAddToPackageJson": false
|
2024
|
+
},
|
2025
|
+
"@angular-eslint/utils": {
|
2026
|
+
"version": "^20.2.0",
|
2027
|
+
"alwaysAddToPackageJson": false
|
2028
|
+
},
|
2029
|
+
"@angular-eslint/schematics": {
|
2030
|
+
"version": "^20.2.0",
|
2031
|
+
"alwaysAddToPackageJson": false
|
2032
|
+
},
|
2033
|
+
"@angular-eslint/test-utils": {
|
2034
|
+
"version": "^20.2.0",
|
2035
|
+
"alwaysAddToPackageJson": false
|
2036
|
+
},
|
2037
|
+
"@angular-eslint/builder": {
|
2038
|
+
"version": "^20.2.0",
|
2039
|
+
"alwaysAddToPackageJson": false
|
2040
|
+
},
|
2041
|
+
"@angular-eslint/bundled-angular-compiler": {
|
2042
|
+
"version": "^20.2.0",
|
2043
|
+
"alwaysAddToPackageJson": false
|
2044
|
+
}
|
2045
|
+
}
|
2046
|
+
},
|
2047
|
+
"21.5.0-@angular-eslint": {
|
2048
|
+
"version": "21.5.0-beta.2",
|
2049
|
+
"requires": {
|
2050
|
+
"@angular/core": ">= 20.0.0 < 21.0.0",
|
2051
|
+
"eslint": "^8.57.0 || ^9.0.0"
|
2052
|
+
},
|
2053
|
+
"packages": {
|
2054
|
+
"@angular-eslint/eslint-plugin": {
|
2055
|
+
"version": "^20.2.0",
|
2056
|
+
"alwaysAddToPackageJson": false
|
2057
|
+
},
|
2058
|
+
"@angular-eslint/eslint-plugin-template": {
|
2059
|
+
"version": "^20.2.0",
|
2060
|
+
"alwaysAddToPackageJson": false
|
2061
|
+
},
|
2062
|
+
"@angular-eslint/template-parser": {
|
2063
|
+
"version": "^20.2.0",
|
2064
|
+
"alwaysAddToPackageJson": false
|
2065
|
+
},
|
2066
|
+
"@angular-eslint/utils": {
|
2067
|
+
"version": "^20.2.0",
|
2068
|
+
"alwaysAddToPackageJson": false
|
2069
|
+
},
|
2070
|
+
"@angular-eslint/schematics": {
|
2071
|
+
"version": "^20.2.0",
|
2072
|
+
"alwaysAddToPackageJson": false
|
2073
|
+
},
|
2074
|
+
"@angular-eslint/test-utils": {
|
2075
|
+
"version": "^20.2.0",
|
2076
|
+
"alwaysAddToPackageJson": false
|
2077
|
+
},
|
2078
|
+
"@angular-eslint/builder": {
|
2079
|
+
"version": "^20.2.0",
|
2080
|
+
"alwaysAddToPackageJson": false
|
2081
|
+
},
|
2082
|
+
"@angular-eslint/bundled-angular-compiler": {
|
2083
|
+
"version": "^20.2.0",
|
2084
|
+
"alwaysAddToPackageJson": false
|
2085
|
+
}
|
2086
|
+
}
|
1918
2087
|
}
|
1919
2088
|
}
|
1920
2089
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@nx/angular",
|
3
|
-
"version": "21.5.0-beta.
|
3
|
+
"version": "21.5.0-beta.2",
|
4
4
|
"private": false,
|
5
5
|
"description": "The Nx Plugin for Angular contains executors, generators, and utilities for managing Angular applications and libraries within an Nx workspace. It provides: \n\n- Integration with libraries such as Storybook, Jest, ESLint, Tailwind CSS, Playwright and Cypress. \n\n- Generators to help scaffold code quickly (like: Micro Frontends, Libraries, both internal to your codebase and publishable to npm) \n\n- Single Component Application Modules (SCAMs) \n\n- NgRx helpers. \n\n- Utilities for automatic workspace refactoring.",
|
6
6
|
"repository": {
|
@@ -58,14 +58,14 @@
|
|
58
58
|
"migrations": "./migrations.json"
|
59
59
|
},
|
60
60
|
"dependencies": {
|
61
|
-
"@nx/devkit": "21.5.0-beta.
|
62
|
-
"@nx/eslint": "21.5.0-beta.
|
63
|
-
"@nx/js": "21.5.0-beta.
|
64
|
-
"@nx/module-federation": "21.5.0-beta.
|
65
|
-
"@nx/rspack": "21.5.0-beta.
|
66
|
-
"@nx/web": "21.5.0-beta.
|
67
|
-
"@nx/webpack": "21.5.0-beta.
|
68
|
-
"@nx/workspace": "21.5.0-beta.
|
61
|
+
"@nx/devkit": "21.5.0-beta.2",
|
62
|
+
"@nx/eslint": "21.5.0-beta.2",
|
63
|
+
"@nx/js": "21.5.0-beta.2",
|
64
|
+
"@nx/module-federation": "21.5.0-beta.2",
|
65
|
+
"@nx/rspack": "21.5.0-beta.2",
|
66
|
+
"@nx/web": "21.5.0-beta.2",
|
67
|
+
"@nx/webpack": "21.5.0-beta.2",
|
68
|
+
"@nx/workspace": "21.5.0-beta.2",
|
69
69
|
"@phenomnomnominal/tsquery": "~5.0.1",
|
70
70
|
"@typescript-eslint/type-utils": "^8.0.0",
|
71
71
|
"enquirer": "~2.3.6",
|
package/spec/src/migrations/update-21-5-0/remove-default-karma-configuration-files.spec.d.ts.map
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"remove-default-karma-configuration-files.spec.d.ts","sourceRoot":"","sources":["../../../../../../../packages/angular/src/migrations/update-21-5-0/remove-default-karma-configuration-files.spec.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"update-angular-cli.spec.d.ts","sourceRoot":"","sources":["../../../../../../../packages/angular/src/migrations/update-21-5-0/update-angular-cli.spec.ts"],"names":[],"mappings":""}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/builders/dev-server/dev-server.impl.ts"],"names":[],"mappings":"AAkCA,OAAO,KAAK,EAAoB,MAAM,EAAE,MAAM,UAAU,CAAC;
|
1
|
+
{"version":3,"file":"dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/builders/dev-server/dev-server.impl.ts"],"names":[],"mappings":"AAkCA,OAAO,KAAK,EAAoB,MAAM,EAAE,MAAM,UAAU,CAAC;AAYzD,wBAAgB,uBAAuB,CACrC,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,OAAO,2BAA2B,EAAE,cAAc,6FAsM5D;wBAII,GAAG;AAFR,wBAES"}
|
@@ -153,7 +153,8 @@ function executeDevServerBuilder(rawOptions, context) {
|
|
153
153
|
// run the target for all projects.
|
154
154
|
// This will occur when workspaceDependencies = []
|
155
155
|
if (workspaceDependencies.length > 0) {
|
156
|
-
baseWebpackConfig.plugins.push(new webpack_nx_build_coordination_plugin_1.WebpackNxBuildCoordinationPlugin(`nx run-many --target=${parsedBuildTarget.target} --projects=${workspaceDependencies.join(',')}`, { skipWatchingDeps: !options.watchDependencies }))
|
156
|
+
baseWebpackConfig.plugins.push(new webpack_nx_build_coordination_plugin_1.WebpackNxBuildCoordinationPlugin(`nx run-many --target=${parsedBuildTarget.target} --projects=${workspaceDependencies.join(',')}`, { skipWatchingDeps: !options.watchDependencies }) // TODO(Colum): this can be removed when angular 20.2 is merged
|
157
|
+
);
|
157
158
|
}
|
158
159
|
}
|
159
160
|
if (!pathToWebpackConfig) {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"webpack-browser.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/builders/webpack-browser/webpack-browser.impl.ts"],"names":[],"mappings":"AAaA,OAAO,EAAQ,UAAU,EAAE,MAAM,MAAM,CAAC;AAQxC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;
|
1
|
+
{"version":3,"file":"webpack-browser.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/builders/webpack-browser/webpack-browser.impl.ts"],"names":[],"mappings":"AAaA,OAAO,EAAQ,UAAU,EAAE,MAAM,MAAM,CAAC;AAQxC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AA+CrD,wBAAgB,4BAA4B,CAC1C,OAAO,EAAE,oBAAoB,EAC7B,OAAO,EAAE,OAAO,2BAA2B,EAAE,cAAc,GAC1D,UAAU,CAAC,OAAO,2BAA2B,EAAE,aAAa,CAAC,CAwG/D;wBAII,GAAG;AAFR,wBAES"}
|
@@ -45,6 +45,22 @@ const operators_2 = require("rxjs/operators");
|
|
45
45
|
const builder_package_1 = require("../../executors/utilities/builder-package");
|
46
46
|
const buildable_libs_1 = require("../utilities/buildable-libs");
|
47
47
|
const webpack_1 = require("../utilities/webpack");
|
48
|
+
// This is required to ensure that the webpack version used by the Module Federation is the same as the one used by the builders.
|
49
|
+
const Module = require('module');
|
50
|
+
const originalResolveFilename = Module._resolveFilename;
|
51
|
+
const patchedWebpackPath = require.resolve('webpack', {
|
52
|
+
paths: [require.resolve('@angular-devkit/build-angular')],
|
53
|
+
});
|
54
|
+
// Override the resolve function
|
55
|
+
Module._resolveFilename = function (request, parent, isMain, options) {
|
56
|
+
// Intercept webpack specifically
|
57
|
+
if (request === 'webpack') {
|
58
|
+
// Force webpack to resolve from your specific path
|
59
|
+
return patchedWebpackPath;
|
60
|
+
}
|
61
|
+
// For all other modules, use the original resolver
|
62
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
63
|
+
};
|
48
64
|
function shouldSkipInitialTargetRun(projectGraph, project, target) {
|
49
65
|
const allTargetNames = new Set();
|
50
66
|
for (const projectName in projectGraph.nodes) {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"webpack-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/builders/webpack-server/webpack-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AAQzE,OAAO,EAAE,UAAU,EAAQ,MAAM,MAAM,CAAC;AAKxC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;
|
1
|
+
{"version":3,"file":"webpack-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/builders/webpack-server/webpack-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AAQzE,OAAO,EAAE,UAAU,EAAQ,MAAM,MAAM,CAAC;AAKxC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAmGlC,wBAAgB,2BAA2B,CACzC,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,cAAc,GACtB,UAAU,CAAC,mBAAmB,CAAC,CAiBjC;wBAII,GAAG;AAFR,wBAES"}
|
@@ -42,6 +42,22 @@ const operators_1 = require("rxjs/operators");
|
|
42
42
|
const builder_package_1 = require("../../executors/utilities/builder-package");
|
43
43
|
const buildable_libs_1 = require("../utilities/buildable-libs");
|
44
44
|
const webpack_1 = require("../utilities/webpack");
|
45
|
+
// This is required to ensure that the webpack version used by the Module Federation is the same as the one used by the builders.
|
46
|
+
const Module = require('module');
|
47
|
+
const originalResolveFilename = Module._resolveFilename;
|
48
|
+
const patchedWebpackPath = require.resolve('webpack', {
|
49
|
+
paths: [require.resolve('@angular-devkit/build-angular')],
|
50
|
+
});
|
51
|
+
// Override the resolve function
|
52
|
+
Module._resolveFilename = function (request, parent, isMain, options) {
|
53
|
+
// Intercept webpack specifically
|
54
|
+
if (request === 'webpack') {
|
55
|
+
// Force webpack to resolve from your specific path
|
56
|
+
return patchedWebpackPath;
|
57
|
+
}
|
58
|
+
// For all other modules, use the original resolver
|
59
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
60
|
+
};
|
45
61
|
function buildServerApp(options, context) {
|
46
62
|
(0, builder_package_1.assertBuilderPackageIsInstalled)('@angular-devkit/build-angular');
|
47
63
|
const { buildLibsFromSource, customWebpackConfig, ...delegateOptions } = options;
|
package/src/executors/module-federation-dev-server/module-federation-dev-server.impl.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"module-federation-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/executors/module-federation-dev-server/module-federation-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,eAAe,EAGrB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,UAAU,CAAC;
|
1
|
+
{"version":3,"file":"module-federation-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/executors/module-federation-dev-server/module-federation-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,eAAe,EAGrB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,UAAU,CAAC;AAwCvC,wBAAuB,iCAAiC,CACtD,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,eAAe,iCAgIzB;AAED,eAAe,iCAAiC,CAAC"}
|
@@ -14,6 +14,22 @@ const dev_server_impl_1 = require("../../builders/dev-server/dev-server.impl");
|
|
14
14
|
const module_federation_1 = require("../../builders/utilities/module-federation");
|
15
15
|
const path_1 = require("path");
|
16
16
|
const fs_1 = require("fs");
|
17
|
+
// This is required to ensure that the webpack version used by the Module Federation is the same as the one used by the builders.
|
18
|
+
const Module = require('module');
|
19
|
+
const originalResolveFilename = Module._resolveFilename;
|
20
|
+
const patchedWebpackPath = require.resolve('webpack', {
|
21
|
+
paths: [require.resolve('@angular-devkit/build-angular')],
|
22
|
+
});
|
23
|
+
// Override the resolve function
|
24
|
+
Module._resolveFilename = function (request, parent, isMain, options) {
|
25
|
+
// Intercept webpack specifically
|
26
|
+
if (request === 'webpack') {
|
27
|
+
// Force webpack to resolve from your specific path
|
28
|
+
return patchedWebpackPath;
|
29
|
+
}
|
30
|
+
// For all other modules, use the original resolver
|
31
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
32
|
+
};
|
17
33
|
async function* moduleFederationDevServerExecutor(schema, context) {
|
18
34
|
const options = (0, lib_1.normalizeOptions)(schema);
|
19
35
|
const { projects: workspaceProjects } = (0, devkit_1.readProjectsConfigurationFromProjectGraph)(context.projectGraph);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"module-federation-ssr-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,eAAe,EAAU,MAAM,YAAY,CAAC;AAoB1D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;
|
1
|
+
{"version":3,"file":"module-federation-ssr-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,eAAe,EAAU,MAAM,YAAY,CAAC;AAoB1D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAsBvC,wBAAuB,oCAAoC,CACzD,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,eAAe,+FA4HzB;AAED,eAAe,oCAAoC,CAAC"}
|
package/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.js
CHANGED
@@ -47,6 +47,22 @@ const module_federation_1 = require("../../builders/utilities/module-federation"
|
|
47
47
|
const builder_package_1 = require("../utilities/builder-package");
|
48
48
|
const normalize_options_1 = require("./lib/normalize-options");
|
49
49
|
const start_dev_remotes_1 = require("./lib/start-dev-remotes");
|
50
|
+
// This is required to ensure that the webpack version used by the Module Federation is the same as the one used by the builders.
|
51
|
+
const Module = require('module');
|
52
|
+
const originalResolveFilename = Module._resolveFilename;
|
53
|
+
const patchedWebpackPath = require.resolve('webpack', {
|
54
|
+
paths: [require.resolve('@angular-devkit/build-angular')],
|
55
|
+
});
|
56
|
+
// Override the resolve function
|
57
|
+
Module._resolveFilename = function (request, parent, isMain, options) {
|
58
|
+
// Intercept webpack specifically
|
59
|
+
if (request === 'webpack') {
|
60
|
+
// Force webpack to resolve from your specific path
|
61
|
+
return patchedWebpackPath;
|
62
|
+
}
|
63
|
+
// For all other modules, use the original resolver
|
64
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
65
|
+
};
|
50
66
|
async function* moduleFederationSsrDevServerExecutor(schema, context) {
|
51
67
|
const options = (0, normalize_options_1.normalizeOptions)(schema);
|
52
68
|
(0, builder_package_1.assertBuilderPackageIsInstalled)('@angular-devkit/build-angular');
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"convert-to-rspack.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/generators/convert-to-rspack/convert-to-rspack.ts"],"names":[],"mappings":"AAAA,OAAO,EAcL,KAAK,iBAAiB,EAEtB,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;
|
1
|
+
{"version":3,"file":"convert-to-rspack.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/generators/convert-to-rspack/convert-to-rspack.ts"],"names":[],"mappings":"AAAA,OAAO,EAcL,KAAK,iBAAiB,EAEtB,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;AAapB,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AA6StD,wBAAsB,eAAe,CACnC,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,qBAAqB,8BAuY9B;AAED,eAAe,eAAe,CAAC"}
|
@@ -8,6 +8,7 @@ const enquirer_1 = require("enquirer");
|
|
8
8
|
const path_1 = require("path");
|
9
9
|
const posix_1 = require("path/posix");
|
10
10
|
const versions_1 = require("../../utils/versions");
|
11
|
+
const version_utils_1 = require("../utils/version-utils");
|
11
12
|
const create_config_1 = require("./lib/create-config");
|
12
13
|
const get_custom_webpack_config_1 = require("./lib/get-custom-webpack-config");
|
13
14
|
const update_tsconfig_1 = require("./lib/update-tsconfig");
|
@@ -249,6 +250,10 @@ async function convertToRspack(tree, schema) {
|
|
249
250
|
const targetsToRemove = [];
|
250
251
|
let customWebpackConfigPath;
|
251
252
|
(0, validate_supported_executor_1.validateSupportedBuildExecutor)(Object.values(project.targets));
|
253
|
+
const angularRspackVersion = (0, version_utils_1.getAngularRspackVersion)(tree);
|
254
|
+
if (!angularRspackVersion) {
|
255
|
+
throw new Error('Angular Rspack requires Angular 19 or higher. Please upgrade your Angular version before converting to Rspack.');
|
256
|
+
}
|
252
257
|
let projectServePort = DEFAULT_PORT;
|
253
258
|
for (const [targetName, target] of Object.entries(project.targets)) {
|
254
259
|
if (target.executor === '@angular-devkit/build-angular:browser' ||
|
@@ -491,10 +496,11 @@ async function convertToRspack(tree, schema) {
|
|
491
496
|
(0, devkit_1.writeJson)(tree, 'package.json', rootPkgJson);
|
492
497
|
}
|
493
498
|
if (!schema.skipInstall) {
|
499
|
+
const { webpackMergeVersion, tsNodeVersion } = (0, version_utils_1.versions)(tree);
|
494
500
|
const installTask = (0, devkit_1.addDependenciesToPackageJson)(tree, {}, {
|
495
|
-
'@nx/angular-rspack':
|
496
|
-
'webpack-merge':
|
497
|
-
'ts-node':
|
501
|
+
'@nx/angular-rspack': angularRspackVersion,
|
502
|
+
'webpack-merge': webpackMergeVersion,
|
503
|
+
'ts-node': tsNodeVersion,
|
498
504
|
});
|
499
505
|
tasks.push(installTask);
|
500
506
|
}
|
@@ -20,12 +20,12 @@ function fixBootstrap(tree, appRoot, options) {
|
|
20
20
|
if (tree.exists((0, devkit_1.joinPathFragments)(appRoot, 'public/module-federation.manifest.json'))) {
|
21
21
|
manifestPath = '/module-federation.manifest.json';
|
22
22
|
}
|
23
|
-
const fetchMFManifestCode = `import {
|
23
|
+
const fetchMFManifestCode = `import { registerRemotes } from '@module-federation/enhanced/runtime';
|
24
24
|
|
25
25
|
fetch('${manifestPath}')
|
26
26
|
.then((res) => res.json())
|
27
27
|
.then((remotes: Record<string, string>) => Object.entries(remotes).map(([name, entry]) => ({ name,entry})))
|
28
|
-
.then(remotes =>
|
28
|
+
.then(remotes => registerRemotes(remotes))
|
29
29
|
.then(() => ${bootstrapImportCode});`;
|
30
30
|
tree.write(mainFilePath, fetchMFManifestCode);
|
31
31
|
}
|
@@ -13,4 +13,9 @@ export declare function getInstalledPackageVersionInfo(tree: Tree, pkgName: stri
|
|
13
13
|
version: string;
|
14
14
|
};
|
15
15
|
export declare function versions(tree: Tree): PackageLatestVersions | PackageCompatVersions;
|
16
|
+
/**
|
17
|
+
* Temporary helper to abstract away the version of angular-rspack to be installed
|
18
|
+
* until we stop supporting Angular 19.
|
19
|
+
*/
|
20
|
+
export declare function getAngularRspackVersion(tree: Tree): string | null;
|
16
21
|
//# sourceMappingURL=version-utils.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"version-utils.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/generators/utils/version-utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,IAAI,EAAE,MAAM,YAAY,CAAC;AAEjD,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC3B,MAAM,0CAA0C,CAAC;AAIlD,wBAAgB,gCAAgC,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,GAAG,IAAI,CAK1E;AAED,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAgB7D;AAED,wBAAgB,+BAA+B,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAElE;AAED,wBAAgB,8BAA8B,CAAC,IAAI,EAAE,IAAI;;;EAOxD;AAED,wBAAgB,0BAA0B,CACxC,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,MAAM,GACd,MAAM,GAAG,IAAI,CAKf;AAED,wBAAgB,8BAA8B,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM;;;EAIzE;AAED,wBAAgB,QAAQ,CACtB,IAAI,EAAE,IAAI,GACT,qBAAqB,GAAG,qBAAqB,CAU/C"}
|
1
|
+
{"version":3,"file":"version-utils.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/generators/utils/version-utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,IAAI,EAAE,MAAM,YAAY,CAAC;AAEjD,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC3B,MAAM,0CAA0C,CAAC;AAIlD,wBAAgB,gCAAgC,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,GAAG,IAAI,CAK1E;AAED,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAgB7D;AAED,wBAAgB,+BAA+B,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAElE;AAED,wBAAgB,8BAA8B,CAAC,IAAI,EAAE,IAAI;;;EAOxD;AAED,wBAAgB,0BAA0B,CACxC,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,MAAM,GACd,MAAM,GAAG,IAAI,CAKf;AAED,wBAAgB,8BAA8B,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM;;;EAIzE;AAED,wBAAgB,QAAQ,CACtB,IAAI,EAAE,IAAI,GACT,qBAAqB,GAAG,qBAAqB,CAU/C;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,GAAG,IAAI,CAcjE"}
|
@@ -7,6 +7,7 @@ exports.getInstalledAngularVersionInfo = getInstalledAngularVersionInfo;
|
|
7
7
|
exports.getInstalledPackageVersion = getInstalledPackageVersion;
|
8
8
|
exports.getInstalledPackageVersionInfo = getInstalledPackageVersionInfo;
|
9
9
|
exports.versions = versions;
|
10
|
+
exports.getAngularRspackVersion = getAngularRspackVersion;
|
10
11
|
const tslib_1 = require("tslib");
|
11
12
|
const devkit_1 = require("@nx/devkit");
|
12
13
|
const semver_1 = require("semver");
|
@@ -57,3 +58,20 @@ function versions(tree) {
|
|
57
58
|
return latestVersions;
|
58
59
|
}
|
59
60
|
}
|
61
|
+
/**
|
62
|
+
* Temporary helper to abstract away the version of angular-rspack to be installed
|
63
|
+
* until we stop supporting Angular 19.
|
64
|
+
*/
|
65
|
+
function getAngularRspackVersion(tree) {
|
66
|
+
const majorAngularVersion = getInstalledAngularMajorVersion(tree);
|
67
|
+
if (majorAngularVersion === 19) {
|
68
|
+
return backward_compatible_versions_1.backwardCompatibleVersions.angularV19.angularRspackVersion;
|
69
|
+
}
|
70
|
+
if (majorAngularVersion >= 20) {
|
71
|
+
// Starting with Angular 20, we can use an Angular Rspack version that is
|
72
|
+
// aligned with the Nx version
|
73
|
+
return latestVersions.nxVersion;
|
74
|
+
}
|
75
|
+
// Lower versions of Angular are not supported
|
76
|
+
return null;
|
77
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"remove-default-karma-configuration-files.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/migrations/update-21-5-0/remove-default-karma-configuration-files.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;AAQpB,yBAA+B,IAAI,EAAE,IAAI,iBA4DxC"}
|
@@ -0,0 +1,53 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.default = default_1;
|
4
|
+
const devkit_1 = require("@nx/devkit");
|
5
|
+
const targets_1 = require("../../utils/targets");
|
6
|
+
const karma_config_analyzer_1 = require("./utils/karma-config-analyzer");
|
7
|
+
const karma_config_comparer_1 = require("./utils/karma-config-comparer");
|
8
|
+
async function default_1(tree) {
|
9
|
+
const removableKarmaConfigs = new Map();
|
10
|
+
const projects = (0, devkit_1.getProjects)(tree);
|
11
|
+
for (const [projectName, project] of projects) {
|
12
|
+
for (const [, target] of (0, targets_1.allProjectTargets)(project)) {
|
13
|
+
let needDevkitPlugin = false;
|
14
|
+
switch (target.executor) {
|
15
|
+
case '@angular-devkit/build-angular:karma':
|
16
|
+
needDevkitPlugin = true;
|
17
|
+
break;
|
18
|
+
case '@angular/build:karma':
|
19
|
+
break;
|
20
|
+
default:
|
21
|
+
continue;
|
22
|
+
}
|
23
|
+
for (const [, options] of (0, targets_1.allTargetOptions)(target)) {
|
24
|
+
const karmaConfig = options['karmaConfig'];
|
25
|
+
if (typeof karmaConfig !== 'string') {
|
26
|
+
continue;
|
27
|
+
}
|
28
|
+
let isRemovable = removableKarmaConfigs.get(karmaConfig);
|
29
|
+
if (isRemovable === undefined && tree.exists(karmaConfig)) {
|
30
|
+
const content = tree.read(karmaConfig, 'utf-8');
|
31
|
+
const analysis = (0, karma_config_analyzer_1.analyzeKarmaConfig)(content);
|
32
|
+
if (analysis.hasUnsupportedValues) {
|
33
|
+
// Cannot safely determine if the file is removable.
|
34
|
+
isRemovable = false;
|
35
|
+
}
|
36
|
+
else {
|
37
|
+
const diff = await (0, karma_config_comparer_1.compareKarmaConfigToDefault)(analysis, projectName, karmaConfig, needDevkitPlugin);
|
38
|
+
isRemovable = !(0, karma_config_comparer_1.hasDifferences)(diff) && diff.isReliable;
|
39
|
+
}
|
40
|
+
removableKarmaConfigs.set(karmaConfig, isRemovable);
|
41
|
+
if (isRemovable) {
|
42
|
+
tree.delete(karmaConfig);
|
43
|
+
}
|
44
|
+
}
|
45
|
+
if (isRemovable) {
|
46
|
+
delete options['karmaConfig'];
|
47
|
+
(0, devkit_1.updateProjectConfiguration)(tree, projectName, project);
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
}
|
52
|
+
await (0, devkit_1.formatFiles)(tree);
|
53
|
+
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"set-tsconfig-option.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/migrations/update-21-5-0/set-tsconfig-option.ts"],"names":[],"mappings":"AAAA,OAAO,EAOL,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;AAUpB,yBAA+B,IAAI,EAAE,IAAI,
|
1
|
+
{"version":3,"file":"set-tsconfig-option.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/migrations/update-21-5-0/set-tsconfig-option.ts"],"names":[],"mappings":"AAAA,OAAO,EAOL,KAAK,IAAI,EACV,MAAM,YAAY,CAAC;AAUpB,yBAA+B,IAAI,EAAE,IAAI,iBAwBxC"}
|
@@ -17,10 +17,14 @@ async function default_1(tree) {
|
|
17
17
|
try {
|
18
18
|
// we're only updating static project configurations, not inferred ones
|
19
19
|
const projectConfig = (0, devkit_1.readProjectConfiguration)(tree, project.name);
|
20
|
+
let wasUpdated = false;
|
20
21
|
for (const target of relevantTargets(projectConfig)) {
|
21
22
|
updateTarget(tree, projectConfig, target);
|
23
|
+
wasUpdated = true;
|
24
|
+
}
|
25
|
+
if (wasUpdated) {
|
26
|
+
(0, devkit_1.updateProjectConfiguration)(tree, project.name, projectConfig);
|
22
27
|
}
|
23
|
-
(0, devkit_1.updateProjectConfiguration)(tree, project.name, projectConfig);
|
24
28
|
}
|
25
29
|
catch {
|
26
30
|
// ignore, it can happen if the project is fully inferred and there's no
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"update-angular-cli.d.ts","sourceRoot":"","sources":["../../../../../../packages/angular/src/migrations/update-21-5-0/update-angular-cli.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAAc,MAAM,YAAY,CAAC;AAE3D,eAAO,MAAM,iBAAiB,YAAY,CAAC;AAE3C,yBAA+B,IAAI,EAAE,IAAI,iBAkBxC"}
|
@@ -0,0 +1,23 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.angularCliVersion = void 0;
|
4
|
+
exports.default = default_1;
|
5
|
+
const devkit_1 = require("@nx/devkit");
|
6
|
+
exports.angularCliVersion = '~20.2.0';
|
7
|
+
async function default_1(tree) {
|
8
|
+
let shouldFormat = false;
|
9
|
+
(0, devkit_1.updateJson)(tree, 'package.json', (json) => {
|
10
|
+
if (json.devDependencies?.['@angular/cli']) {
|
11
|
+
json.devDependencies['@angular/cli'] = exports.angularCliVersion;
|
12
|
+
shouldFormat = true;
|
13
|
+
}
|
14
|
+
else if (json.dependencies?.['@angular/cli']) {
|
15
|
+
json.dependencies['@angular/cli'] = exports.angularCliVersion;
|
16
|
+
shouldFormat = true;
|
17
|
+
}
|
18
|
+
return json;
|
19
|
+
});
|
20
|
+
if (shouldFormat) {
|
21
|
+
await (0, devkit_1.formatFiles)(tree);
|
22
|
+
}
|
23
|
+
}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
/**
|
2
|
+
* @license
|
3
|
+
* Copyright Google LLC All Rights Reserved.
|
4
|
+
*
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
6
|
+
* found in the LICENSE file at https://angular.dev/license
|
7
|
+
*/
|
8
|
+
export interface RequireInfo {
|
9
|
+
module: string;
|
10
|
+
export?: string;
|
11
|
+
isCall?: boolean;
|
12
|
+
arguments?: KarmaConfigValue[];
|
13
|
+
}
|
14
|
+
export type KarmaConfigValue = string | boolean | number | KarmaConfigValue[] | {
|
15
|
+
[key: string]: KarmaConfigValue;
|
16
|
+
} | RequireInfo | undefined;
|
17
|
+
export interface KarmaConfigAnalysis {
|
18
|
+
settings: Map<string, KarmaConfigValue>;
|
19
|
+
hasUnsupportedValues: boolean;
|
20
|
+
}
|
21
|
+
/**
|
22
|
+
* Analyzes the content of a Karma configuration file to extract its settings.
|
23
|
+
*
|
24
|
+
* @param content The string content of the `karma.conf.js` file.
|
25
|
+
* @returns An object containing the configuration settings and a flag indicating if unsupported values were found.
|
26
|
+
*/
|
27
|
+
export declare function analyzeKarmaConfig(content: string): KarmaConfigAnalysis;
|
28
|
+
//# sourceMappingURL=karma-config-analyzer.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"karma-config-analyzer.d.ts","sourceRoot":"","sources":["../../../../../../../packages/angular/src/migrations/update-21-5-0/utils/karma-config-analyzer.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAqBH,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAChC;AAED,MAAM,MAAM,gBAAgB,GACxB,MAAM,GACN,OAAO,GACP,MAAM,GACN,gBAAgB,EAAE,GAClB;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,gBAAgB,CAAA;CAAE,GACnC,WAAW,GACX,SAAS,CAAC;AAEd,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC;IACxC,oBAAoB,EAAE,OAAO,CAAC;CAC/B;AAID;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,mBAAmB,CA+HvE"}
|
@@ -0,0 +1,139 @@
|
|
1
|
+
"use strict";
|
2
|
+
/**
|
3
|
+
* @license
|
4
|
+
* Copyright Google LLC All Rights Reserved.
|
5
|
+
*
|
6
|
+
* Use of this source code is governed by an MIT-style license that can be
|
7
|
+
* found in the LICENSE file at https://angular.dev/license
|
8
|
+
*/
|
9
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
10
|
+
exports.analyzeKarmaConfig = analyzeKarmaConfig;
|
11
|
+
/**
|
12
|
+
* Adapts the private utility from Angular CLI to be used in the migration.
|
13
|
+
*/
|
14
|
+
const ensure_typescript_1 = require("@nx/js/src/utils/typescript/ensure-typescript");
|
15
|
+
let ts;
|
16
|
+
/**
|
17
|
+
* Analyzes the content of a Karma configuration file to extract its settings.
|
18
|
+
*
|
19
|
+
* @param content The string content of the `karma.conf.js` file.
|
20
|
+
* @returns An object containing the configuration settings and a flag indicating if unsupported values were found.
|
21
|
+
*/
|
22
|
+
function analyzeKarmaConfig(content) {
|
23
|
+
if (!ts) {
|
24
|
+
ts = (0, ensure_typescript_1.ensureTypescript)();
|
25
|
+
}
|
26
|
+
const sourceFile = ts.createSourceFile('karma.conf.js', content, ts.ScriptTarget.Latest, true);
|
27
|
+
const settings = new Map();
|
28
|
+
let hasUnsupportedValues = false;
|
29
|
+
function visit(node) {
|
30
|
+
// The Karma configuration is defined within a `config.set({ ... })` call.
|
31
|
+
if (ts.isCallExpression(node) &&
|
32
|
+
ts.isPropertyAccessExpression(node.expression) &&
|
33
|
+
node.expression.expression.getText(sourceFile) === 'config' &&
|
34
|
+
node.expression.name.text === 'set' &&
|
35
|
+
node.arguments.length === 1 &&
|
36
|
+
ts.isObjectLiteralExpression(node.arguments[0])) {
|
37
|
+
// We found `config.set`, now we extract the properties from the object literal.
|
38
|
+
for (const prop of node.arguments[0].properties) {
|
39
|
+
if (isSupportedPropertyAssignment(prop)) {
|
40
|
+
const key = prop.name.text;
|
41
|
+
const value = extractValue(prop.initializer);
|
42
|
+
settings.set(key, value);
|
43
|
+
}
|
44
|
+
else {
|
45
|
+
hasUnsupportedValues = true;
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
49
|
+
else {
|
50
|
+
ts.forEachChild(node, visit);
|
51
|
+
}
|
52
|
+
}
|
53
|
+
function extractValue(node) {
|
54
|
+
switch (node.kind) {
|
55
|
+
case ts.SyntaxKind.StringLiteral:
|
56
|
+
return node.text;
|
57
|
+
case ts.SyntaxKind.NumericLiteral:
|
58
|
+
return Number(node.text);
|
59
|
+
case ts.SyntaxKind.TrueKeyword:
|
60
|
+
return true;
|
61
|
+
case ts.SyntaxKind.FalseKeyword:
|
62
|
+
return false;
|
63
|
+
case ts.SyntaxKind.Identifier: {
|
64
|
+
const identifier = node.text;
|
65
|
+
if (identifier === '__dirname' || identifier === '__filename') {
|
66
|
+
return identifier;
|
67
|
+
}
|
68
|
+
break;
|
69
|
+
}
|
70
|
+
case ts.SyntaxKind.CallExpression: {
|
71
|
+
const callExpr = node;
|
72
|
+
// Handle require('...')
|
73
|
+
if (ts.isIdentifier(callExpr.expression) &&
|
74
|
+
callExpr.expression.text === 'require' &&
|
75
|
+
callExpr.arguments.length === 1 &&
|
76
|
+
ts.isStringLiteral(callExpr.arguments[0])) {
|
77
|
+
return { module: callExpr.arguments[0].text };
|
78
|
+
}
|
79
|
+
// Handle calls on a require, e.g. require('path').join()
|
80
|
+
const calleeValue = extractValue(callExpr.expression);
|
81
|
+
if (isRequireInfo(calleeValue)) {
|
82
|
+
return {
|
83
|
+
...calleeValue,
|
84
|
+
isCall: true,
|
85
|
+
arguments: callExpr.arguments.map(extractValue),
|
86
|
+
};
|
87
|
+
}
|
88
|
+
break;
|
89
|
+
}
|
90
|
+
case ts.SyntaxKind.PropertyAccessExpression: {
|
91
|
+
const propAccessExpr = node;
|
92
|
+
// Handle config constants like `config.LOG_INFO`
|
93
|
+
if (ts.isIdentifier(propAccessExpr.expression) &&
|
94
|
+
propAccessExpr.expression.text === 'config') {
|
95
|
+
return `config.${propAccessExpr.name.text}`;
|
96
|
+
}
|
97
|
+
const value = extractValue(propAccessExpr.expression);
|
98
|
+
if (isRequireInfo(value)) {
|
99
|
+
const currentExport = value.export
|
100
|
+
? `${value.export}.${propAccessExpr.name.text}`
|
101
|
+
: propAccessExpr.name.text;
|
102
|
+
return { ...value, export: currentExport };
|
103
|
+
}
|
104
|
+
break;
|
105
|
+
}
|
106
|
+
case ts.SyntaxKind.ArrayLiteralExpression:
|
107
|
+
return node.elements.map(extractValue);
|
108
|
+
case ts.SyntaxKind.ObjectLiteralExpression: {
|
109
|
+
const obj = {};
|
110
|
+
for (const prop of node.properties) {
|
111
|
+
if (isSupportedPropertyAssignment(prop)) {
|
112
|
+
// Recursively extract values for nested objects.
|
113
|
+
obj[prop.name.text] = extractValue(prop.initializer);
|
114
|
+
}
|
115
|
+
else {
|
116
|
+
hasUnsupportedValues = true;
|
117
|
+
}
|
118
|
+
}
|
119
|
+
return obj;
|
120
|
+
}
|
121
|
+
}
|
122
|
+
// For complex expressions (like variables) that we don't need to resolve,
|
123
|
+
// we mark the analysis as potentially incomplete.
|
124
|
+
hasUnsupportedValues = true;
|
125
|
+
return undefined;
|
126
|
+
}
|
127
|
+
visit(sourceFile);
|
128
|
+
return { settings, hasUnsupportedValues };
|
129
|
+
}
|
130
|
+
function isRequireInfo(value) {
|
131
|
+
return (typeof value === 'object' &&
|
132
|
+
value !== null &&
|
133
|
+
!Array.isArray(value) &&
|
134
|
+
'module' in value);
|
135
|
+
}
|
136
|
+
function isSupportedPropertyAssignment(prop) {
|
137
|
+
return (ts.isPropertyAssignment(prop) &&
|
138
|
+
(ts.isIdentifier(prop.name) || ts.isStringLiteral(prop.name)));
|
139
|
+
}
|
@@ -0,0 +1,64 @@
|
|
1
|
+
/**
|
2
|
+
* @license
|
3
|
+
* Copyright Google LLC All Rights Reserved.
|
4
|
+
*
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
6
|
+
* found in the LICENSE file at https://angular.dev/license
|
7
|
+
*/
|
8
|
+
import { type KarmaConfigAnalysis, type KarmaConfigValue } from './karma-config-analyzer';
|
9
|
+
/**
|
10
|
+
* Represents the difference between two Karma configurations.
|
11
|
+
*/
|
12
|
+
export interface KarmaConfigDiff {
|
13
|
+
/** A map of settings that were added in the project's configuration. */
|
14
|
+
added: Map<string, KarmaConfigValue>;
|
15
|
+
/** A map of settings that were removed from the project's configuration. */
|
16
|
+
removed: Map<string, KarmaConfigValue>;
|
17
|
+
/** A map of settings that were modified between the two configurations. */
|
18
|
+
modified: Map<string, {
|
19
|
+
projectValue: KarmaConfigValue;
|
20
|
+
defaultValue: KarmaConfigValue;
|
21
|
+
}>;
|
22
|
+
/** A boolean indicating if the comparison is reliable (i.e., no unsupported values were found). */
|
23
|
+
isReliable: boolean;
|
24
|
+
}
|
25
|
+
/**
|
26
|
+
* Generates the default Karma configuration file content as a string.
|
27
|
+
* @param relativePathToWorkspaceRoot The relative path from the Karma config file to the workspace root.
|
28
|
+
* @param projectName The name of the project.
|
29
|
+
* @param needDevkitPlugin A boolean indicating if the devkit plugin is needed.
|
30
|
+
* @returns The content of the default `karma.conf.js` file.
|
31
|
+
*/
|
32
|
+
export declare function generateDefaultKarmaConfig(relativePathToWorkspaceRoot: string, projectName: string, needDevkitPlugin: boolean): Promise<string>;
|
33
|
+
/**
|
34
|
+
* Compares two Karma configuration analyses and returns the difference.
|
35
|
+
* @param projectAnalysis The analysis of the project's configuration.
|
36
|
+
* @param defaultAnalysis The analysis of the default configuration to compare against.
|
37
|
+
* @returns A diff object representing the changes between the two configurations.
|
38
|
+
*/
|
39
|
+
export declare function compareKarmaConfigs(projectAnalysis: KarmaConfigAnalysis, defaultAnalysis: KarmaConfigAnalysis): KarmaConfigDiff;
|
40
|
+
/**
|
41
|
+
* Checks if there are any differences in the provided Karma configuration diff.
|
42
|
+
* @param diff The Karma configuration diff object to check.
|
43
|
+
* @returns True if there are any differences; false otherwise.
|
44
|
+
*/
|
45
|
+
export declare function hasDifferences(diff: KarmaConfigDiff): boolean;
|
46
|
+
/**
|
47
|
+
* Compares a project's Karma configuration with the default configuration.
|
48
|
+
* @param projectConfigContent The content of the project's `karma.conf.js` file.
|
49
|
+
* @param projectRoot The root directory of the project.
|
50
|
+
* @param needDevkitPlugin A boolean indicating if the devkit plugin is needed for the default config.
|
51
|
+
* @param karmaConfigPath The path to the Karma configuration file, used to resolve relative paths.
|
52
|
+
* @returns A diff object representing the changes.
|
53
|
+
*/
|
54
|
+
export declare function compareKarmaConfigToDefault(projectConfigContent: string, projectName: string, karmaConfigPath: string, needDevkitPlugin: boolean): Promise<KarmaConfigDiff>;
|
55
|
+
/**
|
56
|
+
* Compares a project's Karma configuration with the default configuration.
|
57
|
+
* @param projectAnalysis The analysis of the project's configuration.
|
58
|
+
* @param projectRoot The root directory of the project.
|
59
|
+
* @param needDevkitPlugin A boolean indicating if the devkit plugin is needed for the default config.
|
60
|
+
* @param karmaConfigPath The path to the Karma configuration file, used to resolve relative paths.
|
61
|
+
* @returns A diff object representing the changes.
|
62
|
+
*/
|
63
|
+
export declare function compareKarmaConfigToDefault(projectAnalysis: KarmaConfigAnalysis, projectName: string, karmaConfigPath: string, needDevkitPlugin: boolean): Promise<KarmaConfigDiff>;
|
64
|
+
//# sourceMappingURL=karma-config-comparer.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"karma-config-comparer.d.ts","sourceRoot":"","sources":["../../../../../../../packages/angular/src/migrations/update-21-5-0/utils/karma-config-comparer.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AASH,OAAO,EAEL,KAAK,mBAAmB,EACxB,KAAK,gBAAgB,EACtB,MAAM,yBAAyB,CAAC;AAEjC;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,wEAAwE;IACxE,KAAK,EAAE,GAAG,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC;IAErC,4EAA4E;IAC5E,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC;IAEvC,2EAA2E;IAC3E,QAAQ,EAAE,GAAG,CACX,MAAM,EACN;QAAE,YAAY,EAAE,gBAAgB,CAAC;QAAC,YAAY,EAAE,gBAAgB,CAAA;KAAE,CACnE,CAAC;IAEF,mGAAmG;IACnG,UAAU,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;GAMG;AACH,wBAAsB,0BAA0B,CAC9C,2BAA2B,EAAE,MAAM,EACnC,WAAW,EAAE,MAAM,EACnB,gBAAgB,EAAE,OAAO,GACxB,OAAO,CAAC,MAAM,CAAC,CAgBjB;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CACjC,eAAe,EAAE,mBAAmB,EACpC,eAAe,EAAE,mBAAmB,GACnC,eAAe,CAoCjB;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,eAAe,GAAG,OAAO,CAE7D;AAED;;;;;;;GAOG;AACH,wBAAsB,2BAA2B,CAC/C,oBAAoB,EAAE,MAAM,EAC5B,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,MAAM,EACvB,gBAAgB,EAAE,OAAO,GACxB,OAAO,CAAC,eAAe,CAAC,CAAC;AAE5B;;;;;;;GAOG;AACH,wBAAsB,2BAA2B,CAC/C,eAAe,EAAE,mBAAmB,EACpC,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,MAAM,EACvB,gBAAgB,EAAE,OAAO,GACxB,OAAO,CAAC,eAAe,CAAC,CAAC"}
|
@@ -0,0 +1,145 @@
|
|
1
|
+
"use strict";
|
2
|
+
/**
|
3
|
+
* @license
|
4
|
+
* Copyright Google LLC All Rights Reserved.
|
5
|
+
*
|
6
|
+
* Use of this source code is governed by an MIT-style license that can be
|
7
|
+
* found in the LICENSE file at https://angular.dev/license
|
8
|
+
*/
|
9
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
10
|
+
exports.generateDefaultKarmaConfig = generateDefaultKarmaConfig;
|
11
|
+
exports.compareKarmaConfigs = compareKarmaConfigs;
|
12
|
+
exports.hasDifferences = hasDifferences;
|
13
|
+
exports.compareKarmaConfigToDefault = compareKarmaConfigToDefault;
|
14
|
+
/**
|
15
|
+
* Adapts the private utility from Angular CLI to be used in the migration.
|
16
|
+
*/
|
17
|
+
const promises_1 = require("node:fs/promises");
|
18
|
+
const node_path_1 = require("node:path");
|
19
|
+
const node_util_1 = require("node:util");
|
20
|
+
const karma_config_analyzer_1 = require("./karma-config-analyzer");
|
21
|
+
/**
|
22
|
+
* Generates the default Karma configuration file content as a string.
|
23
|
+
* @param relativePathToWorkspaceRoot The relative path from the Karma config file to the workspace root.
|
24
|
+
* @param projectName The name of the project.
|
25
|
+
* @param needDevkitPlugin A boolean indicating if the devkit plugin is needed.
|
26
|
+
* @returns The content of the default `karma.conf.js` file.
|
27
|
+
*/
|
28
|
+
async function generateDefaultKarmaConfig(relativePathToWorkspaceRoot, projectName, needDevkitPlugin) {
|
29
|
+
let template = await getKarmaConfigTemplate();
|
30
|
+
// TODO: Replace this with the actual schematic templating logic.
|
31
|
+
template = template
|
32
|
+
.replace(/<%= relativePathToWorkspaceRoot %>/g, (0, node_path_1.normalize)(relativePathToWorkspaceRoot).replace(/\\/g, '/'))
|
33
|
+
.replace(/<%= folderName %>/g, projectName);
|
34
|
+
const devkitPluginRegex = /<% if \(needDevkitPlugin\) { %>(.*?)<% } %>/gs;
|
35
|
+
const replacement = needDevkitPlugin ? '$1' : '';
|
36
|
+
template = template.replace(devkitPluginRegex, replacement);
|
37
|
+
return template;
|
38
|
+
}
|
39
|
+
/**
|
40
|
+
* Compares two Karma configuration analyses and returns the difference.
|
41
|
+
* @param projectAnalysis The analysis of the project's configuration.
|
42
|
+
* @param defaultAnalysis The analysis of the default configuration to compare against.
|
43
|
+
* @returns A diff object representing the changes between the two configurations.
|
44
|
+
*/
|
45
|
+
function compareKarmaConfigs(projectAnalysis, defaultAnalysis) {
|
46
|
+
const added = new Map();
|
47
|
+
const removed = new Map();
|
48
|
+
const modified = new Map();
|
49
|
+
const allKeys = new Set([
|
50
|
+
...projectAnalysis.settings.keys(),
|
51
|
+
...defaultAnalysis.settings.keys(),
|
52
|
+
]);
|
53
|
+
for (const key of allKeys) {
|
54
|
+
const projectValue = projectAnalysis.settings.get(key);
|
55
|
+
const defaultValue = defaultAnalysis.settings.get(key);
|
56
|
+
if (projectValue !== undefined && defaultValue === undefined) {
|
57
|
+
added.set(key, projectValue);
|
58
|
+
}
|
59
|
+
else if (projectValue === undefined && defaultValue !== undefined) {
|
60
|
+
removed.set(key, defaultValue);
|
61
|
+
}
|
62
|
+
else if (projectValue !== undefined && defaultValue !== undefined) {
|
63
|
+
if (!(0, node_util_1.isDeepStrictEqual)(projectValue, defaultValue)) {
|
64
|
+
modified.set(key, { projectValue, defaultValue });
|
65
|
+
}
|
66
|
+
}
|
67
|
+
}
|
68
|
+
return {
|
69
|
+
added,
|
70
|
+
removed,
|
71
|
+
modified,
|
72
|
+
isReliable: !projectAnalysis.hasUnsupportedValues &&
|
73
|
+
!defaultAnalysis.hasUnsupportedValues,
|
74
|
+
};
|
75
|
+
}
|
76
|
+
/**
|
77
|
+
* Checks if there are any differences in the provided Karma configuration diff.
|
78
|
+
* @param diff The Karma configuration diff object to check.
|
79
|
+
* @returns True if there are any differences; false otherwise.
|
80
|
+
*/
|
81
|
+
function hasDifferences(diff) {
|
82
|
+
return diff.added.size > 0 || diff.removed.size > 0 || diff.modified.size > 0;
|
83
|
+
}
|
84
|
+
async function compareKarmaConfigToDefault(projectConfigOrAnalysis, projectName, karmaConfigPath, needDevkitPlugin) {
|
85
|
+
const projectAnalysis = typeof projectConfigOrAnalysis === 'string'
|
86
|
+
? (0, karma_config_analyzer_1.analyzeKarmaConfig)(projectConfigOrAnalysis)
|
87
|
+
: projectConfigOrAnalysis;
|
88
|
+
const defaultContent = await generateDefaultKarmaConfig(relativePathToWorkspaceRoot((0, node_path_1.dirname)(karmaConfigPath)), projectName, needDevkitPlugin);
|
89
|
+
const defaultAnalysis = (0, karma_config_analyzer_1.analyzeKarmaConfig)(defaultContent);
|
90
|
+
return compareKarmaConfigs(projectAnalysis, defaultAnalysis);
|
91
|
+
}
|
92
|
+
function relativePathToWorkspaceRoot(projectRoot) {
|
93
|
+
if (!projectRoot) {
|
94
|
+
return '.';
|
95
|
+
}
|
96
|
+
return (0, node_path_1.relative)((0, node_path_1.join)('/', projectRoot), '/') || '.';
|
97
|
+
}
|
98
|
+
const karmaConfigTemplateFallback = `// Karma configuration file, see link for more information
|
99
|
+
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
100
|
+
|
101
|
+
module.exports = function (config) {
|
102
|
+
config.set({
|
103
|
+
basePath: '',
|
104
|
+
frameworks: ['jasmine'<% if (needDevkitPlugin) { %>, '@angular-devkit/build-angular'<% } %>],
|
105
|
+
plugins: [
|
106
|
+
require('karma-jasmine'),
|
107
|
+
require('karma-chrome-launcher'),
|
108
|
+
require('karma-jasmine-html-reporter'),
|
109
|
+
require('karma-coverage'),<% if (needDevkitPlugin) { %>
|
110
|
+
require('@angular-devkit/build-angular/plugins/karma')<% } %>
|
111
|
+
],
|
112
|
+
client: {
|
113
|
+
jasmine: {
|
114
|
+
// you can add configuration options for Jasmine here
|
115
|
+
// the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html
|
116
|
+
// for example, you can disable the random execution with \`random: false\`
|
117
|
+
// or set a specific seed with \`seed: 4321\`
|
118
|
+
},
|
119
|
+
},
|
120
|
+
jasmineHtmlReporter: {
|
121
|
+
suppressAll: true // removes the duplicated traces
|
122
|
+
},
|
123
|
+
coverageReporter: {
|
124
|
+
dir: require('path').join(__dirname, '<%= relativePathToWorkspaceRoot %>/coverage/<%= folderName %>'),
|
125
|
+
subdir: '.',
|
126
|
+
reporters: [
|
127
|
+
{ type: 'html' },
|
128
|
+
{ type: 'text-summary' }
|
129
|
+
]
|
130
|
+
},
|
131
|
+
reporters: ['progress', 'kjhtml'],
|
132
|
+
browsers: ['Chrome'],
|
133
|
+
restartOnFileChange: true
|
134
|
+
});
|
135
|
+
};
|
136
|
+
`;
|
137
|
+
async function getKarmaConfigTemplate() {
|
138
|
+
try {
|
139
|
+
const templatePath = require.resolve('@schematics/angular/config/files/karma.conf.js.template');
|
140
|
+
return await (0, promises_1.readFile)(templatePath, 'utf-8');
|
141
|
+
}
|
142
|
+
catch (e) {
|
143
|
+
return karmaConfigTemplateFallback;
|
144
|
+
}
|
145
|
+
}
|
@@ -5,7 +5,7 @@ type CompatPackageVersionNames = LatestPackageVersionNames;
|
|
5
5
|
export type PackageVersionNames = LatestPackageVersionNames | CompatPackageVersionNames;
|
6
6
|
export type VersionMap = {
|
7
7
|
angularV18: Record<CompatPackageVersionNames, string>;
|
8
|
-
angularV19: Record<CompatPackageVersionNames, string>;
|
8
|
+
angularV19: Record<CompatPackageVersionNames | 'angularRspackVersion', string>;
|
9
9
|
};
|
10
10
|
export type PackageLatestVersions = Record<LatestPackageVersionNames, string>;
|
11
11
|
export type PackageCompatVersions = VersionMap[SupportedVersions];
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"backward-compatible-versions.d.ts","sourceRoot":"","sources":["../../../../../packages/angular/src/utils/backward-compatible-versions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,cAAc,MAAM,YAAY,CAAC;AAE7C,KAAK,iBAAiB,GAAG,YAAY,GAAG,YAAY,CAAC;AAErD,KAAK,yBAAyB,GAAG,OAAO,CACtC,MAAM,OAAO,cAAc,EAC3B,WAAW,CACZ,CAAC;AACF,KAAK,yBAAyB,GAAG,yBAAyB,CAAC;AAE3D,MAAM,MAAM,mBAAmB,GAC3B,yBAAyB,GACzB,yBAAyB,CAAC;AAE9B,MAAM,MAAM,UAAU,GAAG;IACvB,UAAU,EAAE,MAAM,CAAC,yBAAyB,EAAE,MAAM,CAAC,CAAC;IACtD,UAAU,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"backward-compatible-versions.d.ts","sourceRoot":"","sources":["../../../../../packages/angular/src/utils/backward-compatible-versions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,cAAc,MAAM,YAAY,CAAC;AAE7C,KAAK,iBAAiB,GAAG,YAAY,GAAG,YAAY,CAAC;AAErD,KAAK,yBAAyB,GAAG,OAAO,CACtC,MAAM,OAAO,cAAc,EAC3B,WAAW,CACZ,CAAC;AACF,KAAK,yBAAyB,GAAG,yBAAyB,CAAC;AAE3D,MAAM,MAAM,mBAAmB,GAC3B,yBAAyB,GACzB,yBAAyB,CAAC;AAE9B,MAAM,MAAM,UAAU,GAAG;IACvB,UAAU,EAAE,MAAM,CAAC,yBAAyB,EAAE,MAAM,CAAC,CAAC;IACtD,UAAU,EAAE,MAAM,CAChB,yBAAyB,GAAG,sBAAsB,EAClD,MAAM,CACP,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,MAAM,CAAC,yBAAyB,EAAE,MAAM,CAAC,CAAC;AAC9E,MAAM,MAAM,qBAAqB,GAAG,UAAU,CAAC,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,0BAA0B,EAAE,UA8DxC,CAAC"}
|
package/src/utils/versions.d.ts
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
export declare const nxVersion: any;
|
2
|
-
export declare const angularVersion = "~20.
|
3
|
-
export declare const angularDevkitVersion = "~20.
|
4
|
-
export declare const ngPackagrVersion = "~20.
|
5
|
-
export declare const angularRspackVersion = "^21.1.0";
|
2
|
+
export declare const angularVersion = "~20.2.0";
|
3
|
+
export declare const angularDevkitVersion = "~20.2.0";
|
4
|
+
export declare const ngPackagrVersion = "~20.2.0";
|
6
5
|
export declare const ngrxVersion = "^20.0.0";
|
7
6
|
export declare const rxjsVersion = "~7.8.0";
|
8
7
|
export declare const zoneJsVersion = "~0.15.0";
|
@@ -16,7 +15,7 @@ export declare const browserSyncVersion = "^3.0.0";
|
|
16
15
|
export declare const moduleFederationNodeVersion = "^2.7.11";
|
17
16
|
export declare const moduleFederationEnhancedVersion = "^0.18.0";
|
18
17
|
export declare const webpackMergeVersion = "^5.8.0";
|
19
|
-
export declare const angularEslintVersion = "^20.
|
18
|
+
export declare const angularEslintVersion = "^20.2.0";
|
20
19
|
export declare const typescriptEslintVersion = "^7.16.0";
|
21
20
|
export declare const tailwindVersion = "^3.0.2";
|
22
21
|
export declare const postcssVersion = "^8.4.5";
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../../../packages/angular/src/utils/versions.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,KAAwC,CAAC;AAE/D,eAAO,MAAM,cAAc,YAAY,CAAC;AACxC,eAAO,MAAM,oBAAoB,YAAY,CAAC;AAC9C,eAAO,MAAM,gBAAgB,YAAY,CAAC;AAC1C,eAAO,MAAM,
|
1
|
+
{"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../../../packages/angular/src/utils/versions.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,KAAwC,CAAC;AAE/D,eAAO,MAAM,cAAc,YAAY,CAAC;AACxC,eAAO,MAAM,oBAAoB,YAAY,CAAC;AAC9C,eAAO,MAAM,gBAAgB,YAAY,CAAC;AAC1C,eAAO,MAAM,WAAW,YAAY,CAAC;AACrC,eAAO,MAAM,WAAW,WAAW,CAAC;AACpC,eAAO,MAAM,aAAa,YAAY,CAAC;AACvC,eAAO,MAAM,gBAAgB,UAAU,CAAC;AACxC,eAAO,MAAM,YAAY,WAAW,CAAC;AAErC,eAAO,MAAM,WAAW,WAAW,CAAC;AACpC,eAAO,MAAM,gBAAgB,WAAW,CAAC;AACzC,eAAO,MAAM,cAAc,YAAY,CAAC;AACxC,eAAO,MAAM,mBAAmB,aAAa,CAAC;AAC9C,eAAO,MAAM,kBAAkB,WAAW,CAAC;AAC3C,eAAO,MAAM,2BAA2B,YAAY,CAAC;AACrD,eAAO,MAAM,+BAA+B,YAAY,CAAC;AACzD,eAAO,MAAM,mBAAmB,WAAW,CAAC;AAE5C,eAAO,MAAM,oBAAoB,YAAY,CAAC;AAC9C,eAAO,MAAM,uBAAuB,YAAY,CAAC;AACjD,eAAO,MAAM,eAAe,WAAW,CAAC;AACxC,eAAO,MAAM,cAAc,WAAW,CAAC;AACvC,eAAO,MAAM,iBAAiB,YAAY,CAAC;AAC3C,eAAO,MAAM,mBAAmB,YAAY,CAAC;AAC7C,eAAO,MAAM,aAAa,WAAW,CAAC;AACtC,eAAO,MAAM,WAAW,WAAW,CAAC;AAEpC,eAAO,MAAM,wBAAwB,YAAY,CAAC;AAClD,eAAO,MAAM,gBAAgB,YAAY,CAAC;AAC1C,eAAO,MAAM,qBAAqB,WAAW,CAAC;AAE9C,eAAO,MAAM,wBAAwB,WAAW,CAAC"}
|
package/src/utils/versions.js
CHANGED
@@ -1,11 +1,10 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.jsoncEslintParserVersion = exports.jasmineMarblesVersion = exports.typesNodeVersion = exports.jestPresetAngularVersion = exports.lessVersion = exports.tsNodeVersion = exports.autoprefixerVersion = exports.postcssUrlVersion = exports.postcssVersion = exports.tailwindVersion = exports.typescriptEslintVersion = exports.angularEslintVersion = exports.webpackMergeVersion = exports.moduleFederationEnhancedVersion = exports.moduleFederationNodeVersion = exports.browserSyncVersion = exports.typesExpressVersion = exports.expressVersion = exports.typesCorsVersion = exports.corsVersion = exports.tsLibVersion = exports.angularJsVersion = exports.zoneJsVersion = exports.rxjsVersion = exports.ngrxVersion = exports.
|
3
|
+
exports.jsoncEslintParserVersion = exports.jasmineMarblesVersion = exports.typesNodeVersion = exports.jestPresetAngularVersion = exports.lessVersion = exports.tsNodeVersion = exports.autoprefixerVersion = exports.postcssUrlVersion = exports.postcssVersion = exports.tailwindVersion = exports.typescriptEslintVersion = exports.angularEslintVersion = exports.webpackMergeVersion = exports.moduleFederationEnhancedVersion = exports.moduleFederationNodeVersion = exports.browserSyncVersion = exports.typesExpressVersion = exports.expressVersion = exports.typesCorsVersion = exports.corsVersion = exports.tsLibVersion = exports.angularJsVersion = exports.zoneJsVersion = exports.rxjsVersion = exports.ngrxVersion = exports.ngPackagrVersion = exports.angularDevkitVersion = exports.angularVersion = exports.nxVersion = void 0;
|
4
4
|
exports.nxVersion = require('../../package.json').version;
|
5
|
-
exports.angularVersion = '~20.
|
6
|
-
exports.angularDevkitVersion = '~20.
|
7
|
-
exports.ngPackagrVersion = '~20.
|
8
|
-
exports.angularRspackVersion = '^21.1.0';
|
5
|
+
exports.angularVersion = '~20.2.0';
|
6
|
+
exports.angularDevkitVersion = '~20.2.0';
|
7
|
+
exports.ngPackagrVersion = '~20.2.0';
|
9
8
|
exports.ngrxVersion = '^20.0.0';
|
10
9
|
exports.rxjsVersion = '~7.8.0';
|
11
10
|
exports.zoneJsVersion = '~0.15.0';
|
@@ -19,7 +18,7 @@ exports.browserSyncVersion = '^3.0.0';
|
|
19
18
|
exports.moduleFederationNodeVersion = '^2.7.11';
|
20
19
|
exports.moduleFederationEnhancedVersion = '^0.18.0';
|
21
20
|
exports.webpackMergeVersion = '^5.8.0';
|
22
|
-
exports.angularEslintVersion = '^20.
|
21
|
+
exports.angularEslintVersion = '^20.2.0';
|
23
22
|
exports.typescriptEslintVersion = '^7.16.0';
|
24
23
|
exports.tailwindVersion = '^3.0.2';
|
25
24
|
exports.postcssVersion = '^8.4.5';
|