-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc
62 lines (62 loc) · 1.39 KB
/
.eslintrc
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
{
"settings": {
"react": {
"version": "detect"
}
},
"env": {
"browser": true,
"commonjs": true,
"es2022": true,
"node": true
},
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:react/jsx-runtime",
"plugin:react-hooks/recommended",
"prettier"
],
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 13,
"sourceType": "module"
},
"overrides": [
{
"files": ["*.js", "*.jsx"]
}
],
"plugins": ["simple-import-sort", "sort-destructure-keys"],
"rules": {
"prefer-const": "error",
"react/prop-types": "off",
"react/self-closing-comp": "error",
"react/jsx-no-useless-fragment": "error",
"react/jsx-curly-brace-presence": ["error", "never"],
"react/jsx-fragments": "error",
"react/function-component-definition": [
2,
{ "namedComponents": "function-declaration" }
],
"react/display-name": ["error"],
"react-hooks/exhaustive-deps": "error",
"react/destructuring-assignment": "error",
"simple-import-sort/imports": [
"error",
{
"groups": [
["^react$"],
["^\\u0000"],
["^@?\\w"],
["^components", "^hooks", "^lib", "^public"],
["^"]
]
}
],
"simple-import-sort/exports": "error",
"sort-destructure-keys/sort-destructure-keys": "error"
}
}