NPM basic command

Time:2020-11-22

NPM basic command

npm install xxx

The XXX module is installed but not recorded to package.json in

NPM install XXX @ version number

Install the XXX module with the specified version number

npm install –save xxx

Install XXX module and record to package.json The dependency corresponding to the field is a module that the product environment must rely on

npm install –save-dev xxx

Install XXX module and record to package.json The dev dependency corresponding to the field is a module that the development environment must rely on

npm install –global xxx

Global installation of XXX module, not recorded to package.json

npm uninstall xxx
Delete XXX module

npm uninstall -g xxx
Delete XXX module globally

Recommended Today

Explain module, import and export in JavaScript

Author: Tania rascia Crazy technology house Original text:https://www.taniarascia.com/j… In the era of the Internet, websites are mainly developed with HTML and CSS. If you load JavaScript into a page, it usually provides effects and interactions in the form of small fragments. Generally, all JavaScript code is written in a file and loaded into a filescriptTag. […]