-
Notifications
You must be signed in to change notification settings - Fork 56
/
.eslintrc.js
65 lines (65 loc) · 1.59 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
64
65
module.exports = {
env: {
browser: true,
node: true,
jest: true,
es6: true
},
root: true,
plugins: ["react", "react-hooks"],
parser: "babel-eslint",
parserOptions: {
ecmaVersion: 2017,
sourceType: "module",
ecmaFeatures: {
jsx: true
}
},
extends: ["eslint:recommended", "prettier"],
rules: {
"linebreak-style": ["error", "unix"],
"jsx-quotes": ["error", "prefer-double"],
quotes: ["error", "double"],
semi: ["error", "always"],
"no-trailing-spaces": ["error"],
"no-console": ["off"],
"eol-last": ["error", "always"],
"no-alert": "error",
"no-eval": "error",
"no-implied-eval": "error",
"require-await": "error",
"array-bracket-newline": ["error", "consistent"],
"block-spacing": "error",
"brace-style": ["error", "1tbs", { allowSingleLine: true }],
"comma-dangle": ["error", "never"],
"comma-spacing": [
"error",
{
before: false,
after: true
}
],
"comma-style": ["error", "last"],
"computed-property-spacing": ["error", "never"],
"func-call-spacing": ["error", "never"],
"key-spacing": [
"error",
{
beforeColon: false,
afterColon: true
}
],
"no-lonely-if": "error",
"object-curly-spacing": ["error", "always"],
"no-var": "error",
"prefer-const": "error",
"arrow-spacing": "error",
"react-hooks/exhaustive-deps": 2,
"react/jsx-uses-vars": 1,
"react/jsx-uses-react": 1,
"react/jsx-no-target-blank": [2, { enforceDynamicLinks: "always" }]
},
globals: {
Uint8Array: true
}
};