-
Notifications
You must be signed in to change notification settings - Fork 3
/
eslint.config.js
45 lines (44 loc) · 1.15 KB
/
eslint.config.js
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
import js from '@eslint/js'
import prettier from 'eslint-plugin-prettier/recommended'
import globals from 'globals'
import tseslint from 'typescript-eslint'
// @ts-expect-error: Missing types.
import reactRecommended from 'eslint-plugin-react/configs/recommended.js'
// @ts-expect-error: Missing types.
import reactJsxRuntime from 'eslint-plugin-react/configs/jsx-runtime.js'
export default tseslint.config(
prettier,
js.configs.recommended,
...tseslint.configs.strictTypeChecked,
...tseslint.configs.stylisticTypeChecked,
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
reactRecommended,
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
reactJsxRuntime,
{
ignores: ['build/', 'dist/'],
},
{
languageOptions: {
globals: {
...globals.node,
...globals.browser,
},
parserOptions: {
project: true,
tsconfigRootDir: import.meta.dirname,
},
},
rules: {
'@typescript-eslint/explicit-module-boundary-types': 'off',
'react/prop-types': 'off',
},
},
{
settings: {
react: {
version: 'detect',
},
},
},
)