-
Notifications
You must be signed in to change notification settings - Fork 59
/
.eslintrc.js
63 lines (63 loc) · 1.9 KB
/
.eslintrc.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
module.exports = {
env: {
es2021: true,
},
extends: ["plugin:react/recommended", "standard-with-typescript", "prettier", "plugin:react-hooks/recommended"],
overrides: [],
parserOptions: {
ecmaVersion: "latest",
sourceType: "module",
tsconfigRootDir: __dirname,
parser: "@typescript-eslint/parser",
project: "./tsconfig.json",
},
plugins: ["react", "prettier"],
rules: {
"@typescript-eslint/quotes": [2, "single", { avoidEscape: true }],
"@typescript-eslint/comma-dangle": [2, "always-multiline"],
"@typescript-eslint/semi": [2, "always"],
"@typescript-eslint/member-delimiter-style": [2,
{
"multiline": {
"delimiter": "comma",
"requireLast": true
},
"singleline": {
"delimiter": "comma",
"requireLast": true
},
"overrides": {
"interface": {
"multiline": {
"delimiter": "semi",
"requireLast": true
}
}
}
}],
"@typescript-eslint/consistent-type-definitions": [1, "interface"],
"@typescript-eslint/consistent-type-imports": [2, { prefer: "no-type-imports" }],
"@typescript-eslint/space-before-function-paren": [2, {
"anonymous": "never",
"named": "never",
"asyncArrow": "always"
}],
"@typescript-eslint/no-non-null-assertion": [0],
"@typescript-eslint/no-confusing-void-expression": 'off',
"@typescript-eslint/no-misused-promises": 'off',
"react/jsx-curly-brace-presence": [2, { props: "never", children: "never" }],
"jsx-quotes": [2, "prefer-double"],
"prettier/prettier": [2, {
endOfLine: "auto",
singleQuote: true,
semi: true,
bracketSpacing: true,
trailingComma: "all",
tabWidth: 2,
printWidth: 80,
}],
"no-console": [2],
"react-hooks/rules-of-hooks": [0],
"react-hooks/exhaustive-deps": [1],
},
};