mirror of
https://github.com/denisidoro/navi
synced 2024-11-24 20:43:06 +00:00
add npm and nvm cheetsheet
This commit is contained in:
parent
07412e72ed
commit
830073cd42
2 changed files with 31 additions and 0 deletions
20
cheats/npm.cheat
Normal file
20
cheats/npm.cheat
Normal file
|
@ -0,0 +1,20 @@
|
|||
# initial new package
|
||||
npm init
|
||||
|
||||
# initial immediately a new package
|
||||
npm init -y
|
||||
|
||||
# install all dependencies packages
|
||||
npm install
|
||||
|
||||
# install all dev dependencies packages
|
||||
npm install --save-dev
|
||||
|
||||
# install a specified package
|
||||
npm install <package-name>
|
||||
|
||||
# install a specified dev package
|
||||
npm install <package-name> --save-dev
|
||||
|
||||
# install globally a specified package
|
||||
npm install <package-name> -g
|
11
cheats/nvm.cheat
Normal file
11
cheats/nvm.cheat
Normal file
|
@ -0,0 +1,11 @@
|
|||
# install a specified version of node
|
||||
nvm install <version>
|
||||
|
||||
# list available versions
|
||||
nvm ls-remote
|
||||
|
||||
# use installed node's version
|
||||
nvm use <version>
|
||||
|
||||
# set a node's version as default
|
||||
nvm alias default <version>
|
Loading…
Reference in a new issue