Skip to content

Instantly share code, notes, and snippets.

@fraserxu
Last active March 7, 2017 04:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fraserxu/da3896f1d42ff8cdca104eb0149f5465 to your computer and use it in GitHub Desktop.
Save fraserxu/da3896f1d42ff8cdca104eb0149f5465 to your computer and use it in GitHub Desktop.
The great node yarn upgrade guide

Install node

We recommend use nvm instead of nodenv, you can install nvm with brew install nvm. And then you can use it to install the version we are using.

nvm install 6.10.0

Use the version

nvm use 6.10.0

Check node version

node -v

Install Yarn

If you haven't

brew install yarn

If you already have it

brew update && brew upgrade yarn

Install modules

Just in case yarn and npm does not work well with each other, we clean up the older node_modules and then install with yarn. It will take a while for the first run, but I promise it will be way faster next time.

rm -rf node_modules && yarn 

Install runjs

yarn global add runjs@2.6.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment