chore: expand the webpack example #300
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
workflow_dispatch: | |
push: | |
pull_request: | |
branches: [ $default-branch ] | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Install Node | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 12 | |
- name: Install Yarn | |
run: npm install -g yarn | |
- name: Cache dependencies | |
uses: actions/cache@v2 | |
with: | |
path: ~/.yarn | |
key: ${{ runner.OS }}-node-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.OS }}-node- | |
${{ runner.OS }}- | |
- name: Install dependencies | |
run: yarn --frozen-lockfile | |
- name: Lint | |
run: yarn lint | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Install Node | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 12 | |
- name: Install Yarn | |
run: npm install -g yarn | |
- name: Cache dependencies | |
uses: actions/cache@v2 | |
with: | |
path: ~/.yarn | |
key: ${{ runner.OS }}-node-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.OS }}-node- | |
${{ runner.OS }}- | |
- name: Install dependencies | |
run: yarn --frozen-lockfile | |
- name: Test | |
run: yarn test | |
compile: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Install Node | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 12 | |
- name: Install Yarn | |
run: npm install -g yarn | |
- name: Cache dependencies | |
uses: actions/cache@v2 | |
with: | |
path: ~/.yarn | |
key: ${{ runner.OS }}-node-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.OS }}-node- | |
${{ runner.OS }}- | |
- name: Install dependencies | |
run: yarn --frozen-lockfile | |
- name: Compile | |
run: yarn build |