I would like to update Angular from version 5.0 to version 6.1. The instructions at https://update.angular.io/ suggest using ng update @angular/core
to update. However this updates directly to version 7 instead of version 6.
The ng update
docs suggest that using --to
would update to a specific version. However this does not seem to work. The exact command used is: ng update @angular/core --to 6.1.0
But this updates to 7.0.0
EDIT:
I've tried using --from=5.0.0 --to=6.1.9
but this didn't work. I've noticed we're stil using angular-cli
version 1.6.4
. This version supports --next
which according to the docs should (Default: false) Install the next version, instead of the latest.
However this changes the package.json
to use version 7.0.0
of all @angular/*
packages
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…