Skip to the page

Production and testing · senior

Upgrading Angular and moving from AngularJS

Upgrade one major version at a time with a plan. Moving from AngularJS is a rewrite, not an upgrade.

The notes

What you must know

  • Angular 22 is current; a new major comes every 12 months from v22 (facts.md).
  • Upgrade plan: list every dependency and the Angular versions it supports, check Node and TypeScript needs per step, upgrade one major at a time with ng update, run tests after each step.
  • Do not jump many versions at once; each step has its own migrations.
  • AngularJS support ended on 31 Dec 2021, so there are no official security fixes (paid extended support exists).
  • Modern Angular is a different framework. Options: big-bang rewrite (risky, long freeze), hybrid with ngUpgrade (run both), or incremental feature by feature behind a router or proxy.
  • After the v22 upgrade ng update marks existing components Eager. Plan a gradual move to OnPush.
  • Third-party libraries that assume Zone.js need checking before going zoneless.

The red pen

Common traps: mistake → fix

  • Mistake: I can jump from v12 to v22 in one command

    Fix: upgrade one major at a time.

  • Mistake: Moving from AngularJS is an upgrade

    Fix: it is a rewrite of the app.

Easy to hard

Questions interviewers ask, easy to hard

  1. How would you upgrade a very old Angular app to the latest?
  2. How do you move a big AngularJS app to modern Angular?
  3. What happens to existing components in a v22 upgrade?
  4. What would you check before going zoneless?

Explain it out loud

Explain it out loud to an AI interviewer that follows up, and see where your answer is thin.

Practise by voice

Your first interview is free

Sign up and start with a 15-minute interview with the full report, and an English conversation. No card needed.

Start your free interview