-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.mjs
More file actions
26 lines (25 loc) · 806 Bytes
/
eslint.config.mjs
File metadata and controls
26 lines (25 loc) · 806 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import js from '@eslint/js'
import ts from 'typescript-eslint'
import reactPlugin from 'eslint-plugin-react'
import reactHooksPlugin from 'eslint-plugin-react-hooks'
export default [
{ ignores: ['dist/', 'node_modules/', 'coverage/', '**/.astro/'] },
{ files: ['**/*.{ts,tsx}'], ...js.configs.recommended },
...ts.configs.recommended.map((c) => ({ files: ['**/*.{ts,tsx}'], ...c })),
{
files: ['**/*.{ts,tsx}'],
plugins: {
react: reactPlugin,
'react-hooks': reactHooksPlugin,
},
settings: {
react: { version: 'detect' },
},
rules: {
'react/react-in-jsx-scope': 'off',
'react/prop-types': 'off',
'@typescript-eslint/no-explicit-any': 'warn',
'@typescript-eslint/no-unused-vars': ['warn', { argsIgnorePattern: '^_' }],
},
},
]