I have read the following blogs and documentation
and no clear information about how to migrate from 4.x to 5.
Tried the following commands
npm install
npm install @angular/{animations,common,compiler,compiler-cli,
core,forms,http,platform-browser,platform-browser-dynamic,
platform-server,router}@5.0.0
yarn installation
yarn add @angular/{animations,common,compiler,compiler-cli,
core,forms,http,platform-browser,platform-browser-dynamic,
platform-server,router}@5.0.0
Tried the update guide
npm install @angular/animations@'^5.0.0' @angular/common@'^5.0.0'
@angular/compiler@'^5.0.0' @angular/compiler-cli@'^5.0.0'
@angular/core@'^5.0.0' @angular/forms@'^5.0.0'
@angular/http@'^5.0.0' @angular/platform-browser@'^5.0.0'
@angular/platform-browser-dynamic@'^5.0.0'
@angular/platform-server@'^5.0.0' @angular/router@'^5.0.0'
[email protected] rxjs@'^5.5.2'
npm install [email protected] --save-exact
Nothing worked fine for me. Please help
You need to update all angular provided packages to their latest versions as follows:
npm install [email protected] --save-dev
npm install @angular/common@latest @angular/compiler@latest @angular/compiler-cli@latest @angular/core@latest @angular/forms@latest @angular/http@latest @angular/platform-browser@latest @angular/platform-browser-dynamic@latest @angular/platform-server@latest @angular/router@latest @angular/animations@latest --save
This should do all the necessary. Plus you could also update your angular cli that ships with angular 5 as standard version as follows:
npm uninstall -g @angular/cli
npm cache clean
npm install -g @angular/cli@latest
Here is the official blogpost by Angular team : https://angular-update-guide.firebaseapp.com/. This update guide will help you to migrate from any version to the latest one.
This website made it very easy for me. Put in your version you're upgrading from, and which one you're upgrading to. My app is simple, so it may depend on the complexity of your app.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With