Skip to content

fix unused import and fmt #81

fix unused import and fmt

fix unused import and fmt #81

Workflow file for this run

name: Run tests and update docs
on:
workflow_dispatch:
workflow_call:
push:
branches: [main]
env:
YARN_ENABLE_IMMUTABLE_INSTALLS: false
jobs:
CodeQL-Analysis:
name: CodeQL analysis
runs-on: ubuntu-latest
permissions:
security-events: write # required for all workflows
# only required for workflows in private repositories:
actions: read
contents: read
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: javascript
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java).
# If this step fails, then you should remove it and run the build manually
- name: Autobuild
uses: github/codeql-action/autobuild@v2
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
tests:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18]
steps:
- uses: actions/checkout@v3
- name: Setup Node ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: |
corepack enable
corepack prepare yarn@stable --activate
yarn
- name: Run eslint
run: |
yarn lint
- name: Run tests
run: |
yarn test
- name: Build the component
run: |
yarn build
update-docs:
name: Update documentation website
runs-on: ubuntu-latest
permissions:
contents: read
pages: write
id-token: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- name: Install dependencies
run: |
corepack enable
corepack prepare yarn@stable --activate
yarn
- name: Build docs
run: |
yarn docs:build
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: './docs-dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1