---
- name: Install yarn repo key
  apt_key:
    url: "https://dl.yarnpkg.com/debian/pubkey.gpg"
  become: yes

- name: Install yarn repo
  apt_repository:
    repo: "deb https://dl.yarnpkg.com/debian/ stable main"
  become: yes

- name: Install yarn
  apt:
    name: "yarn"
  become: yes

---
- name: Install yarn repo key
  apt_key:
    url: "https://dl.yarnpkg.com/debian/pubkey.gpg"
  become: yes

- name: Install yarn repo
  apt_repository:
    repo: "deb https://dl.yarnpkg.com/debian/ stable main"
  become: yes

- name: Install yarn
  apt:
    name: "yarn"
  become: yes

- name: Install global modules
  command: "/usr/bin/yarn global add {{ item }}"
  with_items:
    - "@angular/cli"
    - prettier
    - eslint
    - tern
    - create-react-app
    - ember-cli

Install npm global packages with yarn
Install npm global packages with yarn
