How to install yarn
- Run
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
to install nvm - Restart your terminal
- Run
nvm --version
and make sure it returns the version
- Run
nvm install --lts
to install node/npm
--lts
means latest version- Run
node --version
and make sure it returns the version - Run
npm --version
and make sure it returns the version
- Run
npm install -g yarn
to install yarn
-g
means global- Run
yarn --version
and make sure it returns the version
- All done! To install the dependencies for a project,
cd
to the project directory and runyarn install