
Have you had issues moving from angular-cli beta 28.3 or earlier to the newer versions of the CLI?
Try these steps then!
Global Dependency
This one is as easy as:
Specific Project
Note: You do NOT need to have the CLI installed globally for this (although it’s a good idea).
First, ensure you have an npm script in your package.json file that looks like:
In this tutorial I’ll replace ng calls with npm run ng -- (note final space ) for those people who may not be able to upgrade their global package.
Now, let’s get to real work.
Commit everything you have in git, then:
Accept all files from update (which used to be called init) other than app module and component, especially (but not limited to) angular-cli.json, polyfills.ts, package.json and main.ts.
Then go to git undo any unwanted change (deleted packages from package.json, missing scripts or files from angular-cli.json, etc). Undo entire app module and component files if you accepted them by accident.
Then
And you can go roll with npm start / npm run ng -- serve.
All good!
How did I learn that?
As a bonus for coming here, I'm giving away a free newsletter for web developers that you can sign up for from here.
It's not an anything-and-everything link list. It's thoughtfully collected picks of articles and tools, that focus on Angular 2+, ASP.NET (4.x/MVC5 and Core), and other fullstack developer goodies.
Take it for a test ride, and you may unsubscribe any time.
You might also want to support me by checking these out [Thanks]: