diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e0736ff3..7434cf8b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,6 +5,10 @@ on: push: branches: [main] +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + permissions: contents: read diff --git a/.lintstagedrc b/.lintstagedrc index e6a08888..5b1260b7 100644 --- a/.lintstagedrc +++ b/.lintstagedrc @@ -1,5 +1,5 @@ { - "**/*.{js,mjs,ts,tsx,md,mdx,json.yml}": [ + "**/*.{js,mjs,jsx,ts,tsx,md,mdx,json,yml}": [ "eslint --fix", "prettier --check --write" ], diff --git a/eslint.config.mjs b/eslint.config.mjs index c79a995e..4222ab72 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -10,6 +10,14 @@ export default [ globals: globals.node, }, }, + { + files: ['**/*.jsx'], + languageOptions: { + parserOptions: { ecmaFeatures: { jsx: true } }, + // SERVER/CLIENT are compile-time defines from doc-kit, not real globals. + globals: { ...globals.browser, SERVER: 'readonly', CLIENT: 'readonly' }, + }, + }, { ignores: ['node_modules/', 'out/', '.cache/', 'webpack/', 'pages/api'], },