View

$ yarn list

Note ls will not work like for npm.

Install package

Project-scoped

Install package by name. Use -D for --save-dev.

$ yarn add react

$ yarn add -D tslint typescript

Note you cannot use yarn install PACKAGE_NAME anymore.

Global

Install package globally by name.

$ yarn global add tslint

Or

$ yarn add tslint -g

Remove package

Project-scoped

$ yarn remove react

Global

$ yarn global remove react

Install all packages

Install packages listed in package.json.

$ yarn install

Outdated

Check for outdated packages.

$ yarn outdated

Upgrade

Upgrade all packages. Note you cannot use yarn update.

$ yarn upgrade

Upgrade just one package.

$ yarn add react

Or, for the absolute latest, which may conflict with your other packages.

$ yarn add react@latest

Create app

Using the create subcommand.

For React:

$ yarn create react-app my-app

Equivalent of:

$ npx create-react-app my-app