Categories
JavaScript Answers

How to install Yarn in Ubuntu?

Spread the love

To install Yarn in Ubuntu, we add the package repository with Yarn before we install it.

We run

curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list

to add the Yarn package repo.

And then we run

sudo apt-get update && sudo apt-get install yarn

to run apt to install yarn.

By John Au-Yeung

Web developer specializing in React, Vue, and front end development.

Leave a Reply

Your email address will not be published. Required fields are marked *