Dina M.
Dina M.

Reputation: 328

Updating all Angular components

Is there a single command that would upgrade all my Angular components?

When I do ng v in a VS Code terminal (globally) to see my Angular version, I get this:

enter image description here

However, when I go into my project's directory, I get the following:

enter image description here

Is there any way I can upgrade everything to the latest existing versions without having to run commands for every single component?

Upvotes: 2

Views: 2138

Answers (1)

vp310
vp310

Reputation: 330

You should update to next major first, so the ideal path from 12 to 14 is via 13.

  1. ng update @angular/core@13 @angular/cli@13
  2. ng update @angular/core@14 @angular/cli@14

You might want to commit the changes or use --allow-dirty while upgrading.

Upvotes: 4

Related Questions