Skip to content

feat(angular): support angular v22#35851

Draft
leosvelperez wants to merge 6 commits into
masterfrom
angular-v22
Draft

feat(angular): support angular v22#35851
leosvelperez wants to merge 6 commits into
masterfrom
angular-v22

Conversation

@leosvelperez

Copy link
Copy Markdown
Member

No description provided.

@leosvelperez leosvelperez self-assigned this Jun 2, 2026
@netlify

netlify Bot commented Jun 2, 2026

Copy link
Copy Markdown

Deploy Preview for nx-docs ready!

Name Link
🔨 Latest commit fcdd393
🔍 Latest deploy log https://app.netlify.com/projects/nx-docs/deploys/6a294ea35a3cae000875cafe
😎 Deploy Preview https://deploy-preview-35851--nx-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Jun 2, 2026

Copy link
Copy Markdown

Deploy Preview for nx-dev ready!

Name Link
🔨 Latest commit fcdd393
🔍 Latest deploy log https://app.netlify.com/projects/nx-dev/deploys/6a294ea37c9ea90008c0642c
😎 Deploy Preview https://deploy-preview-35851--nx-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@nx-cloud

nx-cloud Bot commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

View your CI Pipeline Execution ↗ for commit fcdd393

Command Status Duration Result
nx affected --targets=lint,test,build,e2e,e2e-c... ✅ Succeeded 19m 8s View ↗
nx run-many -t check-imports check-lock-files c... ✅ Succeeded 5s View ↗
nx-cloud record -- pnpm nx-cloud conformance:check ✅ Succeeded 1m 1s View ↗
nx build workspace-plugin ✅ Succeeded <1s View ↗
nx-cloud record -- nx sync:check ✅ Succeeded 20s View ↗
nx-cloud record -- nx format:check ✅ Succeeded 19s View ↗
nx affected -t e2e-macos-local --parallel=1 --b... ✅ Succeeded 35m 36s View ↗

☁️ Nx Cloud last updated this comment at 2026-06-10 12:36:36 UTC

@leosvelperez leosvelperez force-pushed the angular-v22 branch 2 times, most recently from f861bb9 to 1ff1267 Compare June 3, 2026 09:30
nx-cloud[bot]

This comment was marked as outdated.

@PieterjanDeClippel

PieterjanDeClippel commented Jun 3, 2026

Copy link
Copy Markdown

@leosvelperez Angular 22 release has finally arrived 15 minutes ago

But it seems that nx still relies on the baseUrl, which is deprecated in TS6

● All libraries build now (the trailing-comma fix). But I've hit a genuine conflict around your "remove baseUrl" directive that needs your call. Let me lay it out:

  The constraint matrix (TS6 + nx 22):
  - ./-relative paths, no baseUrl (current): libraries build ✓, but the demos fail — nx's nxViteTsPaths needs baseUrl to resolve workspace @example/* imports, so Rollup can't
  bundle them.
  - non-./ paths + baseUrl (original style): demos resolve ✓, but every tsc-based build errors TS5101 (baseUrl deprecated) ✗.
  - baseUrl + ignoreDeprecations: "6.0": everything works ✓ — and almost certainly also fixes the r-video-player .d.ts issue (vite-plugin-dts would emit the bare
  @example/player-provider specifier instead of the broken relative source path).

  So nx 22's toolchain (nxViteTsPaths, vite-plugin-dts) is fundamentally built around baseUrl; TS6 deprecates it. There's no config that satisfies "no baseUrl AND no
  ignoreDeprecations" with nx 22.

@socket-security

socket-security Bot commented Jun 4, 2026

Copy link
Copy Markdown

All alerts resolved. Learn more about Socket for GitHub.

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

View full report

@softworckx

Copy link
Copy Markdown

Is there an estimated timeline for when this version might be released? 🙏🏼

@robertIsaac

Copy link
Copy Markdown
Contributor

Is there an estimated timeline for when this version might be released? 🙏🏼

I only see drop support for Angular 19 in this PR, so I think they still need more time

nx-cloud[bot]

This comment was marked as outdated.

nx-cloud[bot]

This comment was marked as outdated.

@leosvelperez leosvelperez force-pushed the angular-v22 branch 3 times, most recently from 4c53e04 to 12a0f67 Compare June 9, 2026 07:03
nx-cloud[bot]

This comment was marked as outdated.

@socket-security

socket-security Bot commented Jun 9, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatednpm/​@​angular/​platform-browser@​21.2.0 ⏵ 22.0.0771007598100
Updatednpm/​@​angular/​compiler@​21.2.0 ⏵ 22.0.081 +1100 +1678 +198 +1100
Updatednpm/​@​angular/​core@​21.2.0 ⏵ 22.0.081100 +1679 +198100
Updatednpm/​@​angular/​common@​21.2.0 ⏵ 22.0.01001007998100

View full report

nx-cloud[bot]

This comment was marked as outdated.

nx-cloud[bot]

This comment was marked as outdated.

@nx-cloud nx-cloud Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nx Cloud has identified a flaky task in your failed CI:

🔂 Since the failure was identified as flaky, we triggered a CI rerun by adding an empty commit to this branch.

Nx Cloud View detailed reasoning in Nx Cloud ↗


🎓 Learn more about Self-Healing CI on nx.dev

leosvelperez and others added 2 commits June 10, 2026 08:22
## Current Behavior

`@nx/angular` supports Angular 19, 20, and 21.

## Expected Behavior

Drops support for Angular 19; the minimum supported version is now 20.
Removes the Angular 19 version mappings, compatibility branches, SSR
templates, and the v19-only `serverRouting` option.

> [!NOTE]
> Part of the Angular v22 upgrade. This targets the `angular-v22`
integration branch rather than `master`.

<!-- polygraph-session-start -->
---
[View session information
↗](https://snapshot.app.trypolygraph.com/orgs/69cdc268b6aa527e4129c2b4/sessions/angular-v22.0.0-rc.2-5a2c66d4)
<!-- polygraph-session-end -->

---------

Co-authored-by: nx-cloud[bot] <71083854+nx-cloud[bot]@users.noreply.github.com>
Nx installs and generates TypeScript 5.9. Generated tsconfigs use
options that are hard errors on TypeScript 6 (`moduleResolution: node`,
`esModuleInterop: false`, etc.), so workspaces cannot move to TS 6.

Nx defaults to TypeScript ~6.0.3 while still supporting >=5.8.0.
Generators emit version-appropriate config (`bundler` resolution on TS 6
workspaces, `node10` on TS 5.x), an update migration moves eligible
workspaces to TS 6 and keeps their existing tsconfigs compiling via
`ignoreDeprecations: "6.0"`, and Remix workspaces stay on TS 5.x
(generators error on TS 6 and pin 5.x on fresh setups). The repo itself
builds and tests on TS 6.0.3.

> [!NOTE]
> The Angular 22 toolchain bump and Angular-specific tsconfig fixes land
as a follow-up on this branch. Until then, the Angular 21.2 toolchain
peers `typescript <6.0`, so peer warnings are expected in the interim.

<!-- polygraph-session-start -->
---
[View session information
↗](https://snapshot.app.trypolygraph.com/orgs/69cdc268b6aa527e4129c2b4/sessions/nxc-4501-e52da5bd)
<!-- polygraph-session-end -->

---------

Co-authored-by: nx-cloud[bot] <71083854+nx-cloud[bot]@users.noreply.github.com>
Bumps angular-eslint to v22 (and its now-required @typescript-eslint v8)
for Angular 22 workspaces, and aligns the repo eslint catalog to
^22.0.0.

<!-- polygraph-session-start -->
---
[View session information
↗](https://snapshot.app.trypolygraph.com/orgs/69cdc268b6aa527e4129c2b4/sessions/angular-v22-76d725d8)
<!-- polygraph-session-end -->
…ngular v22 (#35935)

## Current Behavior

`@nx/angular-rspack` exposes `subresourceIntegrity`, but only initial
scripts receive an integrity attribute. Under Angular v22 - whose
`@angular/build` emits an integrity importmap for dynamically imported
chunks - lazy chunks built with `@nx/angular-rspack` ship without
subresource integrity protection.

## Expected Behavior

On Angular v22+, SRI builds emit a `<script type="importmap">` block
carrying a sha384 hash for every lazy chunk, matching `@angular/build`'s
application builder, so dynamically imported chunks are validated by the
browser. Behavior on Angular 20/21 is unchanged.

<!-- polygraph-session-start -->
---
[View session information
↗](https://snapshot.app.trypolygraph.com/orgs/69cdc268b6aa527e4129c2b4/sessions/angular-v22-76d725d8)
<!-- polygraph-session-end -->
…heet processor (#35933)

## Current Behavior

Nx's custom ng-packagr `StylesheetProcessor` sets the browserslist
baseline only for ng-packagr v20 and v21. Under ng-packagr v22 no branch
applies, so it falls back to the generic `browserslist` default and
compiles component CSS for the wrong browser targets.

## Expected Behavior

The processor applies ng-packagr v22's browserslist baseline
(`2026-05-07`), so libraries built with `@nx/angular:package` and
`@nx/angular:ng-packagr-lite` target the same browsers as ng-packagr's
own build pipeline.

<!-- polygraph-session-start -->
---
[View session information
↗](https://snapshot.app.trypolygraph.com/orgs/69cdc268b6aa527e4129c2b4/sessions/angular-v22-76d725d8)
<!-- polygraph-session-end -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants