@nx/angular 23.0.0-beta.20 → 23.0.0-beta.22

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.
Files changed (54) hide show
  1. package/generators.json +8 -4
  2. package/migrations.json +62 -31
  3. package/package.json +8 -8
  4. package/src/executors/module-federation-dev-server/module-federation-dev-server.impl.d.ts.map +1 -1
  5. package/src/executors/module-federation-dev-server/module-federation-dev-server.impl.js +2 -0
  6. package/src/executors/module-federation-dev-server/schema.json +1 -0
  7. package/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.d.ts.map +1 -1
  8. package/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.js +2 -0
  9. package/src/executors/module-federation-ssr-dev-server/schema.json +1 -0
  10. package/src/generators/add-linting/lib/add-angular-eslint-dependencies.js +1 -1
  11. package/src/generators/federate-module/federate-module.d.ts.map +1 -1
  12. package/src/generators/federate-module/federate-module.js +2 -0
  13. package/src/generators/host/host.d.ts.map +1 -1
  14. package/src/generators/host/host.js +2 -0
  15. package/src/generators/remote/remote.d.ts.map +1 -1
  16. package/src/generators/remote/remote.js +2 -0
  17. package/src/generators/setup-mf/setup-mf.d.ts.map +1 -1
  18. package/src/generators/setup-mf/setup-mf.js +2 -0
  19. package/src/migrations/update-20-2-0/add-localize-polyfill-to-targets.md +44 -0
  20. package/src/migrations/update-20-2-0/disable-angular-eslint-prefer-standalone.md +475 -0
  21. package/src/migrations/update-20-2-0/migrate-mf-imports-to-new-package.md +19 -0
  22. package/src/migrations/update-20-2-0/migrate-with-mf-import-to-new-package.md +25 -0
  23. package/src/migrations/update-20-2-0/remove-angular-eslint-rules.md +37 -0
  24. package/src/migrations/update-20-2-0/remove-tailwind-config-from-ng-packagr-executors.md +69 -0
  25. package/src/migrations/update-20-2-0/update-angular-cli.md +49 -0
  26. package/src/migrations/update-20-2-0/update-angular-ssr-imports-to-use-node-entry-point.md +27 -0
  27. package/src/migrations/update-20-3-0/ensure-nx-module-federation-package.md +23 -0
  28. package/src/migrations/update-20-4-0/update-angular-cli.md +49 -0
  29. package/src/migrations/update-20-5-0/update-angular-cli.md +23 -0
  30. package/src/migrations/update-21-0-0/change-data-persistence-operators-imports-to-ngrx-router-store-data-persistence.md +113 -0
  31. package/src/migrations/update-21-0-0/set-continuous-option.md +90 -0
  32. package/src/migrations/update-21-2-0/migrate-provide-server-rendering-import.md +56 -0
  33. package/src/migrations/update-21-2-0/replace-provide-server-routing.md +107 -0
  34. package/src/migrations/update-21-2-0/set-generator-defaults-for-previous-style-guide.md +164 -0
  35. package/src/migrations/update-21-2-0/update-angular-cli.md +23 -0
  36. package/src/migrations/update-21-2-0/update-module-resolution.md +53 -0
  37. package/src/migrations/update-21-3-0/update-angular-cli.md +23 -0
  38. package/src/migrations/update-21-5-0/remove-default-karma-configuration-files.md +122 -0
  39. package/src/migrations/update-21-5-0/set-tsconfig-option.md +114 -0
  40. package/src/migrations/update-21-5-0/update-angular-cli.md +23 -0
  41. package/src/migrations/update-21-6-1/update-angular-cli.md +23 -0
  42. package/src/migrations/update-22-3-0/set-isolated-modules.md +76 -0
  43. package/src/migrations/update-22-3-0/update-jest-preset-angular-setup.md +21 -0
  44. package/src/migrations/update-22-3-0/update-module-resolution.md +81 -0
  45. package/src/migrations/update-22-3-0/update-ssr-webpack-config.md +71 -0
  46. package/src/migrations/update-22-3-0/update-typescript-lib.md +103 -0
  47. package/src/migrations/update-22-3-0/update-unit-test-runner-option.md +33 -0
  48. package/src/migrations/update-23-0-0/migrate-ngrx-generator-defaults.md +46 -0
  49. package/src/migrations/update-23-0-0/migrate-with-mf-import-to-new-package.md +27 -0
  50. package/src/utils/module-federation-deprecation.d.ts +13 -0
  51. package/src/utils/module-federation-deprecation.d.ts.map +1 -0
  52. package/src/utils/module-federation-deprecation.js +49 -0
  53. package/src/utils/versions.d.ts +1 -1
  54. package/src/utils/versions.js +1 -1
@@ -0,0 +1,46 @@
1
+ #### Split `@nx/angular:ngrx` generator defaults across the replacement generators
2
+
3
+ Splits any `@nx/angular:ngrx` generator defaults set in `nx.json` or in project-level `project.json` files across the two replacement generators: `@nx/angular:ngrx-root-store` (for root state) and `@nx/angular:ngrx-feature-store` (for feature state). The `@nx/angular:ngrx` generator was removed in Nx v23.
4
+
5
+ Shared options apply to both keys; `barrels` and `parent` are written only to `@nx/angular:ngrx-feature-store` (the `@nx/angular:ngrx-root-store` schema doesn't accept them). The `minimal` option is written only to `@nx/angular:ngrx-root-store` because its semantics differ between the two new generators (see Notes). The deprecated `module` option is renamed to `parent`. The obsolete `root` toggle is dropped — intent is now expressed by which generator is invoked. Existing defaults already set under the new keys are preserved.
6
+
7
+ #### Examples
8
+
9
+ ##### Before
10
+
11
+ ```json title="nx.json"
12
+ {
13
+ "generators": {
14
+ "@nx/angular:ngrx": {
15
+ "facade": true,
16
+ "minimal": true,
17
+ "barrels": true,
18
+ "module": "libs/my-lib/src/lib/my-lib-module.ts"
19
+ }
20
+ }
21
+ }
22
+ ```
23
+
24
+ ##### After
25
+
26
+ ```json title="nx.json"
27
+ {
28
+ "generators": {
29
+ "@nx/angular:ngrx-root-store": {
30
+ "facade": true,
31
+ "minimal": true
32
+ },
33
+ "@nx/angular:ngrx-feature-store": {
34
+ "facade": true,
35
+ "barrels": true,
36
+ "parent": "libs/my-lib/src/lib/my-lib-module.ts"
37
+ }
38
+ }
39
+ }
40
+ ```
41
+
42
+ #### Notes
43
+
44
+ The `minimal` option is intentionally not propagated to `@nx/angular:ngrx-feature-store`. In the deprecated `@nx/angular:ngrx` generator, `minimal` only gated root-state file generation and was a no-op for feature-state usage. In `@nx/angular:ngrx-feature-store`, `minimal: true` skips template generation while still wiring imports to the (now missing) files, which would produce broken modules.
45
+
46
+ The split is otherwise intentionally inclusive: shared options are written to both new keys so users can trim the ones they don't want. CLI invocations of `@nx/angular:ngrx` (in shell scripts, CI, or `package.json`) are not migrated — update those manually to call `@nx/angular:ngrx-root-store` or `@nx/angular:ngrx-feature-store`.
@@ -0,0 +1,27 @@
1
+ #### Update withModuleFederation Import to New Package
2
+
3
+ Updates the `withModuleFederation` and `withModuleFederationForSSR` imports to use `@nx/module-federation/angular`. The `@nx/angular/module-federation` re-export path was deprecated in Nx v20.2 and is now removed.
4
+
5
+ #### Examples
6
+
7
+ ##### Before
8
+
9
+ ```ts title="apps/shell/webpack.config.ts"
10
+ import {
11
+ withModuleFederation,
12
+ withModuleFederationForSSR,
13
+ } from '@nx/angular/module-federation';
14
+ ```
15
+
16
+ ##### After
17
+
18
+ ```ts title="apps/shell/webpack.config.ts"
19
+ import {
20
+ withModuleFederation,
21
+ withModuleFederationForSSR,
22
+ } from '@nx/module-federation/angular';
23
+ ```
24
+
25
+ #### Notes
26
+
27
+ This migration runs for all projects in the workspace that depend on `@nx/angular`, ensuring imports are updated when migrating to Nx v23.
@@ -0,0 +1,13 @@
1
+ export declare const ANGULAR_HOST_GENERATOR_DEPRECATION_MESSAGE = "The `@nx/angular:host` generator is deprecated and will be removed in Nx v24. Angular Module Federation in Nx is no longer supported. Use `@angular-architects/native-federation` (https://www.npmjs.com/package/@angular-architects/native-federation) for the supported Angular path. See https://nx.dev/docs/technologies/module-federation/consumer-and-provider for the v23 migration guide.";
2
+ export declare const ANGULAR_REMOTE_GENERATOR_DEPRECATION_MESSAGE = "The `@nx/angular:remote` generator is deprecated and will be removed in Nx v24. Angular Module Federation in Nx is no longer supported. Use `@angular-architects/native-federation` (https://www.npmjs.com/package/@angular-architects/native-federation) for the supported Angular path. See https://nx.dev/docs/technologies/module-federation/consumer-and-provider for the v23 migration guide.";
3
+ export declare const ANGULAR_SETUP_MF_GENERATOR_DEPRECATION_MESSAGE = "The `@nx/angular:setup-mf` generator is deprecated and will be removed in Nx v24. Angular Module Federation in Nx is no longer supported. Use `@angular-architects/native-federation` (https://www.npmjs.com/package/@angular-architects/native-federation) for the supported Angular path. See https://nx.dev/docs/technologies/module-federation/consumer-and-provider for the v23 migration guide.";
4
+ export declare const ANGULAR_FEDERATE_MODULE_GENERATOR_DEPRECATION_MESSAGE = "The `@nx/angular:federate-module` generator is deprecated and will be removed in Nx v24. Angular Module Federation in Nx is no longer supported. Use `@angular-architects/native-federation` (https://www.npmjs.com/package/@angular-architects/native-federation) for the supported Angular path. See https://nx.dev/docs/technologies/module-federation/consumer-and-provider for the v23 migration guide.";
5
+ export declare const ANGULAR_MF_DEV_SERVER_EXECUTOR_DEPRECATION_MESSAGE = "The `@nx/angular:module-federation-dev-server` executor is deprecated and will be removed in Nx v24. Angular Module Federation in Nx is no longer supported. Use `@angular-architects/native-federation` (https://www.npmjs.com/package/@angular-architects/native-federation) for the supported Angular path. See https://nx.dev/docs/technologies/module-federation/consumer-and-provider for the v23 migration guide.";
6
+ export declare const ANGULAR_MF_DEV_SSR_EXECUTOR_DEPRECATION_MESSAGE = "The `@nx/angular:module-federation-dev-ssr` executor is deprecated and will be removed in Nx v24. Angular Module Federation in Nx is no longer supported. Use `@angular-architects/native-federation` (https://www.npmjs.com/package/@angular-architects/native-federation) for the supported Angular path. See https://nx.dev/docs/technologies/module-federation/consumer-and-provider for the v23 migration guide.";
7
+ export declare function warnAngularHostGeneratorDeprecation(): void;
8
+ export declare function warnAngularRemoteGeneratorDeprecation(): void;
9
+ export declare function warnAngularSetupMfGeneratorDeprecation(): void;
10
+ export declare function warnAngularFederateModuleGeneratorDeprecation(): void;
11
+ export declare function warnAngularMfDevServerExecutorDeprecation(): void;
12
+ export declare function warnAngularMfDevSsrExecutorDeprecation(): void;
13
+ //# sourceMappingURL=module-federation-deprecation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module-federation-deprecation.d.ts","sourceRoot":"","sources":["../../../../../packages/angular/src/utils/module-federation-deprecation.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,0CAA0C,sYAA0G,CAAC;AAElK,eAAO,MAAM,4CAA4C,wYAA4G,CAAC;AAEtK,eAAO,MAAM,8CAA8C,0YAA8G,CAAC;AAE1K,eAAO,MAAM,qDAAqD,iZAAqH,CAAC;AAExL,eAAO,MAAM,kDAAkD,6ZAAiI,CAAC;AAEjM,eAAO,MAAM,+CAA+C,0ZAA8H,CAAC;AAE3L,wBAAgB,mCAAmC,IAAI,IAAI,CAE1D;AAED,wBAAgB,qCAAqC,IAAI,IAAI,CAE5D;AAED,wBAAgB,sCAAsC,IAAI,IAAI,CAE7D;AAED,wBAAgB,6CAA6C,IAAI,IAAI,CAEpE;AAUD,wBAAgB,yCAAyC,IAAI,IAAI,CAKhE;AAED,wBAAgB,sCAAsC,IAAI,IAAI,CAK7D"}
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ANGULAR_MF_DEV_SSR_EXECUTOR_DEPRECATION_MESSAGE = exports.ANGULAR_MF_DEV_SERVER_EXECUTOR_DEPRECATION_MESSAGE = exports.ANGULAR_FEDERATE_MODULE_GENERATOR_DEPRECATION_MESSAGE = exports.ANGULAR_SETUP_MF_GENERATOR_DEPRECATION_MESSAGE = exports.ANGULAR_REMOTE_GENERATOR_DEPRECATION_MESSAGE = exports.ANGULAR_HOST_GENERATOR_DEPRECATION_MESSAGE = void 0;
4
+ exports.warnAngularHostGeneratorDeprecation = warnAngularHostGeneratorDeprecation;
5
+ exports.warnAngularRemoteGeneratorDeprecation = warnAngularRemoteGeneratorDeprecation;
6
+ exports.warnAngularSetupMfGeneratorDeprecation = warnAngularSetupMfGeneratorDeprecation;
7
+ exports.warnAngularFederateModuleGeneratorDeprecation = warnAngularFederateModuleGeneratorDeprecation;
8
+ exports.warnAngularMfDevServerExecutorDeprecation = warnAngularMfDevServerExecutorDeprecation;
9
+ exports.warnAngularMfDevSsrExecutorDeprecation = warnAngularMfDevSsrExecutorDeprecation;
10
+ const devkit_1 = require("@nx/devkit");
11
+ // TODO(v24): Remove all Angular Module Federation surfaces from @nx/angular.
12
+ // Angular Native Federation (@angular-architects/native-federation) is the
13
+ // supported Angular MF path going forward; the new @nx/module-federation
14
+ // generators are React-only.
15
+ const MIGRATION_URL = 'https://nx.dev/docs/technologies/module-federation/consumer-and-provider';
16
+ const ANGULAR_NATIVE_FED_URL = 'https://www.npmjs.com/package/@angular-architects/native-federation';
17
+ const ANGULAR_MF_TRAILER = `Angular Module Federation in Nx is no longer supported. Use \`@angular-architects/native-federation\` (${ANGULAR_NATIVE_FED_URL}) for the supported Angular path. See ${MIGRATION_URL} for the v23 migration guide.`;
18
+ exports.ANGULAR_HOST_GENERATOR_DEPRECATION_MESSAGE = `The \`@nx/angular:host\` generator is deprecated and will be removed in Nx v24. ${ANGULAR_MF_TRAILER}`;
19
+ exports.ANGULAR_REMOTE_GENERATOR_DEPRECATION_MESSAGE = `The \`@nx/angular:remote\` generator is deprecated and will be removed in Nx v24. ${ANGULAR_MF_TRAILER}`;
20
+ exports.ANGULAR_SETUP_MF_GENERATOR_DEPRECATION_MESSAGE = `The \`@nx/angular:setup-mf\` generator is deprecated and will be removed in Nx v24. ${ANGULAR_MF_TRAILER}`;
21
+ exports.ANGULAR_FEDERATE_MODULE_GENERATOR_DEPRECATION_MESSAGE = `The \`@nx/angular:federate-module\` generator is deprecated and will be removed in Nx v24. ${ANGULAR_MF_TRAILER}`;
22
+ exports.ANGULAR_MF_DEV_SERVER_EXECUTOR_DEPRECATION_MESSAGE = `The \`@nx/angular:module-federation-dev-server\` executor is deprecated and will be removed in Nx v24. ${ANGULAR_MF_TRAILER}`;
23
+ exports.ANGULAR_MF_DEV_SSR_EXECUTOR_DEPRECATION_MESSAGE = `The \`@nx/angular:module-federation-dev-ssr\` executor is deprecated and will be removed in Nx v24. ${ANGULAR_MF_TRAILER}`;
24
+ function warnAngularHostGeneratorDeprecation() {
25
+ devkit_1.logger.warn(exports.ANGULAR_HOST_GENERATOR_DEPRECATION_MESSAGE);
26
+ }
27
+ function warnAngularRemoteGeneratorDeprecation() {
28
+ devkit_1.logger.warn(exports.ANGULAR_REMOTE_GENERATOR_DEPRECATION_MESSAGE);
29
+ }
30
+ function warnAngularSetupMfGeneratorDeprecation() {
31
+ devkit_1.logger.warn(exports.ANGULAR_SETUP_MF_GENERATOR_DEPRECATION_MESSAGE);
32
+ }
33
+ function warnAngularFederateModuleGeneratorDeprecation() {
34
+ devkit_1.logger.warn(exports.ANGULAR_FEDERATE_MODULE_GENERATOR_DEPRECATION_MESSAGE);
35
+ }
36
+ // Executor warnings fire once per process to avoid flooding dev-server loops.
37
+ const executorWarned = new Set();
38
+ function warnOnce(key, message) {
39
+ if (executorWarned.has(key))
40
+ return;
41
+ executorWarned.add(key);
42
+ devkit_1.logger.warn(message);
43
+ }
44
+ function warnAngularMfDevServerExecutorDeprecation() {
45
+ warnOnce('angular-mf-dev-server', exports.ANGULAR_MF_DEV_SERVER_EXECUTOR_DEPRECATION_MESSAGE);
46
+ }
47
+ function warnAngularMfDevSsrExecutorDeprecation() {
48
+ warnOnce('angular-mf-dev-ssr', exports.ANGULAR_MF_DEV_SSR_EXECUTOR_DEPRECATION_MESSAGE);
49
+ }
@@ -4,7 +4,7 @@ export declare const angularDevkitVersion = "~21.2.0";
4
4
  export declare const ngPackagrVersion = "~21.2.0";
5
5
  export declare const ngrxVersion = "^21.0.0";
6
6
  export declare const rxjsVersion = "~7.8.0";
7
- export declare const zoneJsVersion = "~0.15.0";
7
+ export declare const zoneJsVersion = "~0.16.0";
8
8
  export declare const tsLibVersion = "^2.3.0";
9
9
  export declare const corsVersion = "~2.8.5";
10
10
  export declare const typesCorsVersion = "~2.8.5";
@@ -7,7 +7,7 @@ exports.angularDevkitVersion = '~21.2.0';
7
7
  exports.ngPackagrVersion = '~21.2.0';
8
8
  exports.ngrxVersion = '^21.0.0';
9
9
  exports.rxjsVersion = '~7.8.0';
10
- exports.zoneJsVersion = '~0.15.0';
10
+ exports.zoneJsVersion = '~0.16.0';
11
11
  exports.tsLibVersion = '^2.3.0';
12
12
  exports.corsVersion = '~2.8.5';
13
13
  exports.typesCorsVersion = '~2.8.5';