Skip to content

Commit

Permalink
eslinting
Browse files Browse the repository at this point in the history
  • Loading branch information
allgandalf committed Apr 29, 2024
1 parent ea80534 commit 726d25c
Show file tree
Hide file tree
Showing 5 changed files with 92 additions and 94 deletions.
44 changes: 17 additions & 27 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,38 +1,28 @@
name: Lint
name: lint

on:
push:
branches:
- master
pull_request:
branches:
- master

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

permissions:
contents: read

jobs:
lint:
name: Lint
timeout-minutes: 30
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Set up Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
- name: Checkout 🛎️
uses: actions/checkout@v2.3.1

- name: Set up Node.js 📦
uses: actions/setup-node@v2
with:
node-version: '18'
cache: yarn
- name: Installation
run: yarn
# run: yarn install --immutable # Fails if yarn.lock is modified (unfortunately only works for Yarn 2, and --frozen-lockfile is not the same!)
- name: Check immutable yarn.lock
run: git diff --exit-code
- name: Lint
run: |
echo "::add-matcher::.github/workflows/cspell-problem-matcher.json"
yarn lint:ci
- name: Prettier Code
run: yarn format:diff
node-version: '14'

- name: Install dependencies 🚚
run: npm install

- name: Lint Docusaurus files 🧹
run: npm run lint
8 changes: 8 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import globals from "globals";
import pluginJs from "@eslint/js";


export default [
{languageOptions: { globals: globals.browser }},
pluginJs.configs.recommended,
];
Loading

0 comments on commit 726d25c

Please sign in to comment.