-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.js
More file actions
42 lines (39 loc) · 1.13 KB
/
eslint.config.js
File metadata and controls
42 lines (39 loc) · 1.13 KB
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
import tseslint from 'typescript-eslint';
import eslintPluginReact from 'eslint-plugin-react';
import eslintPluginReactHooks from 'eslint-plugin-react-hooks';
export default [
{
ignores: ['dist/', 'node_modules/']
},
{
files: ['**/*.{ts,tsx}'],
languageOptions: {
parser: tseslint.parser,
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
ecmaFeatures: {
jsx: true
}
}
},
plugins: {
'@typescript-eslint': tseslint.plugin,
'react': eslintPluginReact,
'react-hooks': eslintPluginReactHooks
},
settings: {
react: {
version: 'detect'
}
},
rules: {
// ESLint recommended rules
...tseslint.configs.recommended.rules,
// React recommended rules
...eslintPluginReact.configs.recommended.rules,
// React Hooks recommended rules
...eslintPluginReactHooks.configs.recommended.rules
}
}
];