mirror of
https://github.com/super-linter/super-linter.git
synced 2025-02-23 05:21:04 -05:00
feat: update eslint configuration (#6590)
- Configure linting for more JavaScript files - Configure linting for more TypeScript files - Configure linting for TSX files
This commit is contained in:
parent
3cb5ade630
commit
d0b304a6a5
1 changed files with 39 additions and 3 deletions
|
@ -3,15 +3,18 @@ env:
|
|||
browser: true
|
||||
es6: true
|
||||
jest: true
|
||||
node: true
|
||||
|
||||
extends:
|
||||
- "eslint:recommended"
|
||||
|
||||
ignorePatterns:
|
||||
- "!.*"
|
||||
- "**/node_modules/.*"
|
||||
|
||||
parser: "@typescript-eslint/parser"
|
||||
|
||||
plugins:
|
||||
- "@typescript-eslint"
|
||||
- n
|
||||
- prettier
|
||||
|
||||
overrides:
|
||||
# JSON files
|
||||
|
@ -40,3 +43,36 @@ overrides:
|
|||
parser: jsonc-eslint-parser
|
||||
parserOptions:
|
||||
jsonSyntax: JSON5
|
||||
|
||||
# Javascript files
|
||||
- files:
|
||||
- "**/*.js"
|
||||
- "**/*.mjs"
|
||||
- "**/*.cjs"
|
||||
- "**/*.jsx"
|
||||
extends:
|
||||
- "plugin:react/recommended"
|
||||
parserOptions:
|
||||
sourceType: module
|
||||
ecmaVersion: latest
|
||||
ecmaFeatures:
|
||||
jsx: true
|
||||
modules: true
|
||||
|
||||
# TypeScript files
|
||||
- files:
|
||||
- "**/*.ts"
|
||||
- "**/*.cts"
|
||||
- "**/*.mts"
|
||||
- "**/*.tsx"
|
||||
extends:
|
||||
- "plugin:@typescript-eslint/recommended"
|
||||
- plugin:n/recommended
|
||||
- plugin:react/recommended
|
||||
- prettier
|
||||
parser: "@typescript-eslint/parser"
|
||||
plugins:
|
||||
- "@typescript-eslint"
|
||||
parserOptions:
|
||||
ecmaVersion: latest
|
||||
sourceType: module
|
||||
|
|
Loading…
Add table
Reference in a new issue