Upgrade to Angular 19: align all packages and fix deprecated APIs#63
Merged
Conversation
- Upgrade remaining @angular/* packages to 19.2.18 (@angular/common, forms, platform-browser, platform-browser-dynamic, router) - Replace removed @angular/http with @angular/common/http (HttpClientModule) - Drop deprecated deps: @angular/http, webpack, tsickle, tslint, protractor, core-js, awesome-typescript-loader, rollup - Update tooling: @angular/cli, @angular-devkit/build-angular, ng-packagr, typescript 3.9 → 5.7, zone.js 0.10 → 0.16 - Remove deprecated build options from angular.json (extractCss, aot, buildOptimizer) and drop tslint/protractor architect sections - Update tsconfig: target ES2022, add useDefineForClassFields: false - Update zone.js polyfills import path (zone.js/dist/zone → zone.js) - Simplify CI: remove Angular 11 version-patching workaround, use Node 20, use --configuration production instead of deprecated --prod flag Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This was referenced Apr 13, 2026
ng-packagr 19 validates the entire file passed via -p against its schema, so embedding the config in package.json via the ngPackage key causes "must NOT have additional properties (name)" errors. Extract to a separate ng-package.json and point the build:lib script at it. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Angular 19 defaults components to standalone: true when no flag is set. GanttEditorComponent is declared in NgGanttEditorModule so it must be explicitly marked standalone: false to keep the NgModule-based API. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Angular 17+ removed defaultProject from the workspace config. With multiple projects (dev, packages) Angular 19 refuses to guess which one to build. Remove defaultProject from angular.json and pass 'dev' explicitly to all ng build invocations in CI and package.json scripts. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Angular 19 defaults standalone to true. AppComponent and DemoComponent are declared in AppModule so they need explicit standalone: false. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Completes the Angular 19 upgrade started in #58 (which updated only
@angular/compilerand@angular/core). Brings the entire dependency tree to a consistent Angular 19 state and removes the CI workaround that was patching versions to Angular 11 at build time.Package changes
Runtime deps — upgraded to 19.2.18:
@angular/common10.0.8 → 19.2.18@angular/forms10.0.8 → 19.2.18@angular/platform-browser10.0.8 → 19.2.18@angular/platform-browser-dynamic10.0.8 → 19.2.18@angular/router10.0.8 → 19.2.18zone.js^0.10.3 → ~0.16.0Removed deprecated/unused deps:
@angular/http— removed in Angular 5; replaced withHttpClientModulefrom@angular/common/httpwebpack— not a direct dependency (managed by Angular CLI internally)rxjs: "*"→ pinned to^7.4.0(Angular 19 compatible)core-js— not needed for evergreen browsers with Angular 19tsickle,tslint,protractor,awesome-typescript-loader,rollup— all deprecated/unusedDev tooling — upgraded to Angular 19 compatible versions:
@angular/cli10.0.5 → ~19.2.24@angular-devkit/build-angular~0.900.2 → ~19.2.24@angular-devkit/schematics^9.0.2 → ~19.2.24@angular/compiler-cli10.0.8 → 19.2.18ng-packagr^9.0.0 → ~19.2.2typescript3.9.7 → ~5.7.0ts-node~7.0.0 → ~10.9.0Code changes
src/app/app.module.ts: Replace removedHttpModule(@angular/http) withHttpClientModule(@angular/common/http)src/polyfills.ts: Update zone.js importzone.js/dist/zone→zone.jstsconfig.json: Target ES2022, adduseDefineForClassFields: false(required for Angular decorators)angular.json: Remove deprecated build options (extractCss,aot,buildOptimizer) and drop removedtslint/protractorarchitect sectionsCI changes
Removes the Angular 11 version-patching workaround that was necessary due to inconsistent versions. The CI now does a straightforward install + build against the actual package.json versions. Also upgrades to Node 20 and uses
--configuration productioninstead of the deprecated--prodflag.Test plan
npm run build:lib— library builds with ng-packagr 19npx ng build --configuration production— demo app builds🤖 Generated with Claude Code