global uninstall angular cli

别来无恙 提交于 2020-07-09 17:06:34

问题


Hi I've tried to uninstall global @angular/cli but I still can use ng -v and it reports warning: Your global Angular CLI version (1.7.0) is greater than your local

I tried:

npm uninstall -g angular-cli
npm uninstall -g @angular/cli
npm cache verify

But ng -v still report the warning that my global is greater than local. Please help. Thank you in advance!


回答1:


Use this command to uninstall the angular-cli ,it will update the dependencies and also do try to clear the cache once.

npm uninstall --save-dev angular-cli



回答2:


Try the Following steps to uninstall angular cli completely

npm uninstall -g angular-cli // Use sudo before to give administrator permission
npm uninstall -g @angular/cli // Use sudo before to give administrator permission

npm cache clean or npm cache clean --force

To reinstall the latest version try this

npm install -g @angular/cli@latest


来源:https://stackoverflow.com/questions/49205088/global-uninstall-angular-cli

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!