Npm
Jump to navigation
Jump to search
npm
install package globally
sudo npm install -g [package]
install package local
Install package to ~/node_modules
npm install [package]
To install to another folder:
# to install into parallel with the .npm cache folder... npm install --prefix ~/.npm [package]
# example: npm install --prefix ~/.npm docker-browse
This will create: ~/.npm/node_modules/ ~/.npm/node_modules/docker-browse/ ~/.npm/node_modules/several-other-dependecies/ ~/.npm/package.json ~/.npm/package-lock.json
Node.js
See Node.js