Why do I have to install angular-cli@webpack locally if I have already installed globally?
I did npm install -g angular-cli@webpack.
After I ng new a project, I found that it installs a local 1.0.0-beta.11-webpack.8 .
If I delete it, ng serve complains about the project is not a valid angular-cli project.
you have the option to link to the global path when you create a new project and it will symlink to it with:
ng new <project-name> --link-cli
would it be possible to have an automatic detection, if angular-cli is globally available?
It's ideal to not have a global cli or rely on any global packages. If one can pull a project down and run npm i and have everything needed, that is better IMO.
The global install is what allows you to do stuff like ng new project, while the local one is used afterwards. This is especially relevant when using different versions of global and local, across different projects.
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.