-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.eslintrc
85 lines (85 loc) · 1.77 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
{
"root": true,
"extends": [
"eslint:recommended",
"eslint-config-airbnb-base",
// plugin
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:react/recommended",
"plugin:unicorn/recommended",
"plugin:eslint-comments/recommended",
"plugin:promise/recommended",
"plugin:import/recommended",
"plugin:import/typescript",
// prettier
"plugin:prettier/recommended",
"prettier",
"prettier/@typescript-eslint",
"prettier/react",
"prettier/unicorn"
],
"plugins": ["simple-import-sort", "react-hooks"],
"settings": {
"import/resolver": {
"typescript": {
"alwaysTryTypes": true
}
},
"react": {
"version": "detect"
}
},
"rules": {
"class-methods-use-this": 0,
"sort-imports": 0,
"no-empty": [2, { "allowEmptyCatch": true }],
// react-hooks
"react-hooks/rules-of-hooks": 2,
"react-hooks/exhaustive-deps": 1,
// simple-import-order
"simple-import-sort/sort": [
2,
{
"groups": [["^react$", "^styled-components$"]]
}
],
// typescript
"@typescript-eslint/explicit-function-return-type": 0,
// import
"import/order": 0,
"import/extensions": [
2,
{
"json": "always",
"ts": "never",
"tsx": "never"
}
],
// unicorn
"unicorn/filename-case": [
2,
{
"cases": {
"pascalCase": true,
"camelCase": true
},
"ignore": ["^_"]
}
]
},
"overrides": [
{
"files": ["**/*.tsx"],
"rules": {
"react/prop-types": 0
}
},
{
"files": ["next.config.js"],
"rules": {
"@typescript-eslint/no-var-requires": 0
}
}
]
}