@nx/angular 20.5.0-canary.20250227-6d40b6a → 20.5.0-canary.20250301-1407152

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 CHANGED
@@ -347,6 +347,15 @@
347
347
  },
348
348
  "description": "Update the @angular/cli package version to ~19.1.0.",
349
349
  "factory": "./src/migrations/update-20-4-0/update-angular-cli"
350
+ },
351
+ "update-angular-cli-version-19-2-0": {
352
+ "cli": "nx",
353
+ "version": "20.5.0-beta.5",
354
+ "requires": {
355
+ "@angular/core": ">=19.2.0"
356
+ },
357
+ "description": "Update the @angular/cli package version to ~19.2.0.",
358
+ "factory": "./src/migrations/update-20-5-0/update-angular-cli"
350
359
  }
351
360
  },
352
361
  "packageJsonUpdates": {
@@ -1533,6 +1542,67 @@
1533
1542
  "alwaysAddToPackageJson": false
1534
1543
  }
1535
1544
  }
1545
+ },
1546
+ "20.5.0": {
1547
+ "version": "20.5.0-beta.5",
1548
+ "x-prompt": "Do you want to update the Angular version to v19.2?",
1549
+ "requires": {
1550
+ "@angular/core": ">=19.2.0 <20.0.0-next.0"
1551
+ },
1552
+ "packages": {
1553
+ "@angular-devkit/build-angular": {
1554
+ "version": "~19.2.0",
1555
+ "alwaysAddToPackageJson": false
1556
+ },
1557
+ "@angular-devkit/core": {
1558
+ "version": "~19.2.0",
1559
+ "alwaysAddToPackageJson": false
1560
+ },
1561
+ "@angular-devkit/schematics": {
1562
+ "version": "~19.2.0",
1563
+ "alwaysAddToPackageJson": false
1564
+ },
1565
+ "@angular/build": {
1566
+ "version": "~19.2.0",
1567
+ "alwaysAddToPackageJson": false
1568
+ },
1569
+ "@angular/pwa": {
1570
+ "version": "~19.2.0",
1571
+ "alwaysAddToPackageJson": false
1572
+ },
1573
+ "@angular/ssr": {
1574
+ "version": "~19.2.0",
1575
+ "alwaysAddToPackageJson": false
1576
+ },
1577
+ "@schematics/angular": {
1578
+ "version": "~19.2.0",
1579
+ "alwaysAddToPackageJson": false
1580
+ },
1581
+ "@angular-devkit/architect": {
1582
+ "version": "~0.1902.0",
1583
+ "alwaysAddToPackageJson": false
1584
+ },
1585
+ "@angular-devkit/build-webpack": {
1586
+ "version": "~0.1902.0",
1587
+ "alwaysAddToPackageJson": false
1588
+ },
1589
+ "@angular/core": {
1590
+ "version": "~19.2.0",
1591
+ "alwaysAddToPackageJson": true
1592
+ },
1593
+ "@angular/material": {
1594
+ "version": "~19.2.1",
1595
+ "alwaysAddToPackageJson": false
1596
+ },
1597
+ "@angular/cdk": {
1598
+ "version": "~19.2.1",
1599
+ "alwaysAddToPackageJson": false
1600
+ },
1601
+ "ng-packagr": {
1602
+ "version": "~19.2.0",
1603
+ "alwaysAddToPackageJson": false
1604
+ }
1605
+ }
1536
1606
  }
1537
1607
  }
1538
1608
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/angular",
3
- "version": "20.5.0-canary.20250227-6d40b6a",
3
+ "version": "20.5.0-canary.20250301-1407152",
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": {
@@ -71,13 +71,13 @@
71
71
  "semver": "^7.5.3",
72
72
  "tslib": "^2.3.0",
73
73
  "webpack-merge": "^5.8.0",
74
- "@nx/devkit": "20.5.0-canary.20250227-6d40b6a",
75
- "@nx/js": "20.5.0-canary.20250227-6d40b6a",
76
- "@nx/eslint": "20.5.0-canary.20250227-6d40b6a",
77
- "@nx/webpack": "20.5.0-canary.20250227-6d40b6a",
78
- "@nx/module-federation": "20.5.0-canary.20250227-6d40b6a",
79
- "@nx/web": "20.5.0-canary.20250227-6d40b6a",
80
- "@nx/workspace": "20.5.0-canary.20250227-6d40b6a",
74
+ "@nx/devkit": "20.5.0-canary.20250301-1407152",
75
+ "@nx/js": "20.5.0-canary.20250301-1407152",
76
+ "@nx/eslint": "20.5.0-canary.20250301-1407152",
77
+ "@nx/webpack": "20.5.0-canary.20250301-1407152",
78
+ "@nx/module-federation": "20.5.0-canary.20250301-1407152",
79
+ "@nx/web": "20.5.0-canary.20250301-1407152",
80
+ "@nx/workspace": "20.5.0-canary.20250301-1407152",
81
81
  "piscina": "^4.4.0"
82
82
  },
83
83
  "peerDependencies": {
@@ -78,11 +78,11 @@
78
78
  },
79
79
  "publicHost": {
80
80
  "type": "string",
81
- "description": "The URL that the browser client (or live-reload client, if enabled) should use to connect to the development server. Use for a complex dev server setup, such as one with reverse proxies."
81
+ "description": "The URL that the browser client (or live-reload client, if enabled) should use to connect to the development server. Use for a complex dev server setup, such as one with reverse proxies. This option has no effect when using the 'application' or other esbuild-based builders."
82
82
  },
83
83
  "allowedHosts": {
84
84
  "type": "array",
85
- "description": "List of hosts that are allowed to access the dev server.",
85
+ "description": "List of hosts that are allowed to access the dev server. This option has no effect when using the 'application' or other esbuild-based builders in Angular versions lower than 19.2.0.",
86
86
  "default": [],
87
87
  "items": {
88
88
  "type": "string"
@@ -94,7 +94,7 @@
94
94
  },
95
95
  "disableHostCheck": {
96
96
  "type": "boolean",
97
- "description": "Don't verify connected clients are part of allowed hosts.",
97
+ "description": "Don't verify connected clients are part of allowed hosts. This option has no effect when using the 'application' or other esbuild-based builders in Angular versions lower than 19.2.0.",
98
98
  "default": false
99
99
  },
100
100
  "hmr": {
@@ -1,13 +1,13 @@
1
1
  import { NgModule } from '@angular/core';
2
2
  import { ServerModule } from '@angular/platform-server';<% if(serverRouting) { %>
3
- import { provideServerRoutesConfig } from '@angular/ssr';<% } %>
3
+ import { <%= provideServerRoutingFn %> } from '@angular/ssr';<% } %>
4
4
  import { AppComponent } from './app.component';
5
5
  import { AppModule } from './app.module';<% if(serverRouting) { %>
6
6
  import { serverRoutes } from './app.routes.server';<% } %>
7
7
 
8
8
  @NgModule({
9
9
  imports: [AppModule, ServerModule],<% if(serverRouting) { %>
10
- providers: [provideServerRoutesConfig(serverRoutes)],<% } %>
10
+ providers: [<%= provideServerRoutingFn %>(serverRoutes)],<% } %>
11
11
  bootstrap: [AppComponent],
12
12
  })
13
13
  export class <%= rootModuleClassName %> {}
@@ -61,6 +61,6 @@ if (isMainModule(import.meta.url)) {
61
61
  }
62
62
 
63
63
  /**
64
- * The request handler used by the Angular CLI (dev-server and during build).
64
+ * Request handler used by the Angular CLI (for dev-server and during build) or Firebase Cloud Functions.
65
65
  */
66
66
  export const reqHandler = createNodeRequestHandler(app);
@@ -1,13 +1,13 @@
1
1
  import { mergeApplicationConfig, ApplicationConfig } from '@angular/core';
2
2
  import { provideServerRendering } from '@angular/platform-server';<% if(serverRouting) { %>
3
- import { provideServerRoutesConfig } from '@angular/ssr';<% } %>
3
+ import { <%= provideServerRoutingFn %> } from '@angular/ssr';<% } %>
4
4
  import { appConfig } from './app.config';<% if(serverRouting) { %>
5
5
  import { serverRoutes } from './app.routes.server';<% } %>
6
6
 
7
7
  const serverConfig: ApplicationConfig = {
8
8
  providers: [
9
9
  provideServerRendering()<% if(serverRouting) { %>,
10
- provideServerRoutesConfig(serverRoutes)<% } %>
10
+ <%= provideServerRoutingFn %>(serverRoutes)<% } %>
11
11
  ]
12
12
  };
13
13
 
@@ -63,3 +63,5 @@ if (isMainModule(import.meta.url)) {
63
63
  console.log(`Node Express server listening on http://localhost:${port}`);
64
64
  });
65
65
  }
66
+
67
+ export default app;
@@ -4,6 +4,7 @@ exports.generateSSRFiles = generateSSRFiles;
4
4
  const devkit_1 = require("@nx/devkit");
5
5
  const path_1 = require("path");
6
6
  const version_utils_1 = require("../../utils/version-utils");
7
+ const semver_1 = require("semver");
7
8
  function generateSSRFiles(tree, options) {
8
9
  const project = (0, devkit_1.readProjectConfiguration)(tree, options.project);
9
10
  if (project.targets.server ||
@@ -24,7 +25,17 @@ function generateSSRFiles(tree, options) {
24
25
  pathToFiles = (0, path_1.join)(baseFilesPath, 'pre-v19', options.standalone ? 'standalone-src' : 'ngmodule-src');
25
26
  }
26
27
  const sourceRoot = project.sourceRoot ?? (0, devkit_1.joinPathFragments)(project.root, 'src');
27
- (0, devkit_1.generateFiles)(tree, pathToFiles, sourceRoot, { ...options, tpl: '' });
28
+ const ssrVersion = (0, version_utils_1.getInstalledPackageVersion)(tree, '@angular/ssr');
29
+ const cleanedSsrVersion = ssrVersion
30
+ ? (0, semver_1.clean)(ssrVersion) ?? (0, semver_1.coerce)(ssrVersion).version
31
+ : null;
32
+ (0, devkit_1.generateFiles)(tree, pathToFiles, sourceRoot, {
33
+ ...options,
34
+ provideServerRoutingFn: !cleanedSsrVersion || (0, semver_1.gte)(cleanedSsrVersion, '19.2.0')
35
+ ? 'provideServerRouting'
36
+ : 'provideServerRoutesConfig',
37
+ tpl: '',
38
+ });
28
39
  if (angularMajorVersion >= 19 && !options.serverRouting) {
29
40
  tree.delete((0, devkit_1.joinPathFragments)(sourceRoot, 'app/app.routes.server.ts'));
30
41
  }
@@ -19,7 +19,6 @@ function ensureAngularDependencies(tree) {
19
19
  const rxjsVersion = (0, version_utils_1.getInstalledPackageVersion)(tree, 'rxjs') ?? pkgVersions.rxjsVersion;
20
20
  const tsLibVersion = (0, version_utils_1.getInstalledPackageVersion)(tree, 'tslib') ?? pkgVersions.tsLibVersion;
21
21
  const zoneJsVersion = (0, version_utils_1.getInstalledPackageVersion)(tree, 'zone.js') ?? pkgVersions.zoneJsVersion;
22
- dependencies['@angular/animations'] = angularVersion;
23
22
  dependencies['@angular/common'] = angularVersion;
24
23
  dependencies['@angular/compiler'] = angularVersion;
25
24
  dependencies['@angular/core'] = angularVersion;
@@ -0,0 +1,3 @@
1
+ import { Tree } from '@nx/devkit';
2
+ export declare const angularCliVersion = "~19.2.0";
3
+ export default function (tree: Tree): Promise<void>;
@@ -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 = '~19.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
+ }
@@ -1,7 +1,7 @@
1
1
  export declare const nxVersion: any;
2
- export declare const angularVersion = "~19.1.0";
3
- export declare const angularDevkitVersion = "~19.1.0";
4
- export declare const ngPackagrVersion = "~19.1.0";
2
+ export declare const angularVersion = "~19.2.0";
3
+ export declare const angularDevkitVersion = "~19.2.0";
4
+ export declare const ngPackagrVersion = "~19.2.0";
5
5
  export declare const ngrxVersion = "^19.0.0";
6
6
  export declare const rxjsVersion = "~7.8.0";
7
7
  export declare const zoneJsVersion = "~0.15.0";
@@ -2,9 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.jsoncEslintParserVersion = exports.jasmineMarblesVersion = exports.typesNodeVersion = exports.jestPresetAngularVersion = exports.tsNodeVersion = exports.autoprefixerVersion = exports.postcssUrlVersion = exports.postcssVersion = exports.tailwindVersion = exports.typescriptEslintVersion = exports.angularEslintVersion = 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 = '~19.1.0';
6
- exports.angularDevkitVersion = '~19.1.0';
7
- exports.ngPackagrVersion = '~19.1.0';
5
+ exports.angularVersion = '~19.2.0';
6
+ exports.angularDevkitVersion = '~19.2.0';
7
+ exports.ngPackagrVersion = '~19.2.0';
8
8
  exports.ngrxVersion = '^19.0.0';
9
9
  exports.rxjsVersion = '~7.8.0';
10
10
  exports.zoneJsVersion = '~0.15.0';