Repository navigation
Expand file tree
/
Copy patheslint.config.js
More file actions
67 lines (66 loc) · 1.96 KB
/
Copy patheslint.config.js
File metadata and controls
67 lines (66 loc) · 1.96 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
const importPlugin = require('eslint-plugin-import')
const jsxA11yPlugin = require('eslint-plugin-jsx-a11y')
const reactPlugin = require('eslint-plugin-react')
const reactHooksPlugin = require('eslint-plugin-react-hooks')
module.exports = [
{
ignores: ['assets/**', 'build/**', 'vendor/**', 'node_modules/**'],
linterOptions: {
reportUnusedDisableDirectives: false
}
},
{
files: ['frontend/src/**/*.{js,jsx}'],
plugins: {
import: importPlugin,
'jsx-a11y': jsxA11yPlugin,
react: reactPlugin,
'react-hooks': reactHooksPlugin
},
languageOptions: {
ecmaVersion: 2022,
sourceType: 'module',
parserOptions: {
ecmaFeatures: {
jsx: true
}
}
},
settings: {
react: {
version: '18.3'
},
'import/resolver': {
node: {
extensions: ['.js', '.jsx', '.json']
}
}
},
rules: {
...importPlugin.configs.recommended.rules,
...reactPlugin.configs.recommended.rules,
...reactHooksPlugin.configs.recommended.rules,
...jsxA11yPlugin.configs.recommended.rules,
'react/react-in-jsx-scope': 'off',
'react/jsx-uses-react': 'off',
'react/prop-types': 'off',
'react/no-unknown-property': 'off',
'react/display-name': 'off',
'react/no-unescaped-entities': 'off',
'react/jsx-no-target-blank': 'off',
'react-hooks/exhaustive-deps': 'off',
'react-hooks/set-state-in-effect': 'off',
'react-hooks/immutability': 'off',
'react-hooks/preserve-manual-memoization': 'off',
'react-hooks/refs': 'off',
'react-hooks/purity': 'off',
'import/no-duplicates': 'off',
'import/no-named-as-default': 'off',
'jsx-a11y/click-events-have-key-events': 'off',
'jsx-a11y/no-static-element-interactions': 'off',
'jsx-a11y/label-has-associated-control': 'off',
'jsx-a11y/alt-text': 'off',
'jsx-a11y/no-autofocus': 'off'
}
}
]