Skip to content

feat!: support Angular 22, drop Angular 18 and 19#211

Open
fmalcher wants to merge 1 commit into
mainfrom
feat/angular-22-support
Open

feat!: support Angular 22, drop Angular 18 and 19#211
fmalcher wants to merge 1 commit into
mainfrom
feat/angular-22-support

Conversation

@fmalcher
Copy link
Copy Markdown
Member

@fmalcher fmalcher commented Jun 7, 2026

Closes #209. I went a step further and think we can safely drop support for unsupported Angular versions.

Summary

  • Bump peer/dep ranges to >=20.0.0 <23.0.0 (devkit architect to <0.2300.0); package now installs cleanly against Angular 22.0.0.
  • Drop Angular 18 and 19. Angular 20 is the minimum supported version; v20 LTS runs through 2026-11-28.
  • Bump engines.node to match Angular 20+ (^20.19.0 || ^22.12.0 || >=24.0.0).
  • Bump TypeScript dev dep to ~5.9.3 — Angular 22's devkit .d.ts uses MapIterator<string> (introduced in TS 5.6), which the previous TS 5.2 couldn't resolve and produced Type 'unknown' is not assignable to type 'string' in ng-add.ts.
  • Bump dev @angular-devkit/* to v22 and @types/node to v22.
  • Add test-fixtures/angular-22.json (generated via ng new with Angular CLI 22.0.0); drop the now-unsupported angular-18.json / angular-19.json fixtures and their tests.
  • Update README and a few stale comments mentioning Angular 17-19.

Compatibility notes

Reviewed the Angular CLI 22 changelog. None of the breaking changes affect APIs this package uses:

  • We use only stable BuilderContext, targetFromTargetString, logging, workspaces, schematic types.
  • We don't use the webpack builders (deprecated), @angular-devkit/architect-cli (removed), @angular/build:jest/web-test-runner (removed), @angular/ssr, or @angular/build:dev-server PORT behavior.

Test plan

  • npm run build passes against @angular-devkit/*@22.0.0
  • npm test — all 426 tests pass against @angular-devkit/*@22.0.0
  • Smoke test ng add angular-cli-ghpages against a fresh ng new workspace on Angular 22
  • Smoke test ng deploy --dry-run against an Angular 22 project

Closes #209.

BREAKING CHANGE: Angular 18 and 19 are no longer supported. The minimum
supported Angular version is now 20.0.0; LTS for v20 runs through
2026-11-28.

- Bump peer/dep ranges to >=20.0.0 <23.0.0 (devkit architect to <0.2300.0)
- Bump engines.node to match Angular 20+ requirements
- Bump TypeScript to ~5.9.3 so devkit 22 MapIterator types resolve
- Bump @types/node and dev devkit packages to v22
- Add angular-22.json fixture, drop angular-18/19 fixtures and tests
- Update README to reflect new supported range
Comment thread src/package.json
"types": "index.d.ts",
"engines": {
"node": ">=18.0.0",
"node": "^20.19.0 || ^22.12.0 || >=24.0.0",
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Should we add broader support again? These asre the versions required by Angular itself. However, we could make it > 20 again:

Suggested change
"node": "^20.19.0 || ^22.12.0 || >=24.0.0",
"node": ">=20.0.0",

@JohannesHoppe
Copy link
Copy Markdown
Member

Ich reviewe, sobald ich Zuhause bin.

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.

Support Angular 22

3 participants