Home > Article > Web Front-end > How to use npm to install and delete modules
This time I will show you how to use npminstalldelete modules, what are the precautions for using npm to install and delete modules, the following is a practical case, Let’s take a look.
npm installation module
[npm install xxx] Use npm to install the xxx module to the directory where the current command line is located;
[npm install -g xxx] Use npm to install the global module xxx;
When installing locally, write the module into package.json:
【npm install xxx】Install but do not write to package.json;
【npm install xxx –save】Install and write to package.json’s “depend encies";
[npm install xxx –save-dev] Install and write it into "devDependencies" of package.json.
npm delete module
[npm uninstall xxx]Delete xxx module;
[npm uninstall -g xxx]Delete Global module xxx;
I believe you have mastered the method after reading the case in this article. For more exciting information, please pay attention to other related articles on the PHP Chinese website!
Recommended reading:
How to use vue addRoutes to implement dynamic permission routing menu
How to use the http server in angularjs
The above is the detailed content of How to use npm to install and delete modules. For more information, please follow other related articles on the PHP Chinese website!