name: Frontend
on:
  pull_request:
    types: [opened, edited, reopened, synchronize]
  push:
    branches-ignore:
      - 'gh-pages'
      - 'dependabot/**'

jobs:
  test-frontend:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v3

      - name: Setup
        uses: ./.github/actions/setup
        with:
          node-version: 16

      - name: Frontend tests
        uses: ./.github/actions/frontend-tests

      - name: Frontend build
        run: npm run build
