DEV Community

eavnitech
eavnitech

Posted on

Most useful npm command

Below is the list of the most useful npm command.

  • 1. npm init: to generate the package.json file
  • 2. npm i or npm install: to install all packages of the package.json file
  • 3. npm i -g: install the package globally
  • 4. npm start: It will execute the entry point script you added in the package.json file
  • 5. npm install npm@latest -g: Upgrade the npm package to the latest version
  • 6. npm outdated: list of all out date packages
  • 7. npm list -g: list of all global npm packages
  • 8. npm uninstall "package name": it will uninstall the package
  • 9. npm publish: This is used to publish the package at npmjs

Your suggestion much appreciated

Top comments (0)