-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
55 lines (55 loc) · 1.29 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
module.exports = {
env: {
browser: true,
commonjs: true,
es6: true,
node: true,
},
extends: [
"airbnb-base",
"prettier",
"plugin:jest/recommended",
"prettier/react",
],
globals: {
Atomics: "readonly",
SharedArrayBuffer: "readonly",
},
parserOptions: {
ecmaVersion: 2018,
},
plugins: ["prettier", "jest", "react", "react-hooks"],
rules: {
// configure the prettier plugin
"prettier/prettier": [
"error",
{
trailingComma: "all",
singleQuote: false,
},
],
"no-underscore-dangle": 0,
"consistent-return": 0,
"func-names": 0,
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn", // <--- THIS IS THE NEW RULE
"jsx-a11y/label-has-associated-control": 0,
"react/jsx-props-no-spreading": [
{
html: "ignore",
custom: "ignore",
explicitSpread: "ignore",
},
],
"jsx-a11y/label-has-for": 0,
"consistent-return": 0,
"import/prefer-default-export": 0,
"react/jsx-no-undef": 1,
// disables the windows/unix linebreak checks.
"linebreak-style": 0,
"linebreak-style": [0, "error", "windows"],
"react/prop-types": [0],
"no-underscore-dangle": [0],
"react/prefer-stateless-function": [0],
},
};