This repository has been archived by the owner on Dec 8, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 19
/
.eslintrc.json
141 lines (141 loc) · 4.12 KB
/
.eslintrc.json
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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
{
"extends": ["eslint:recommended", "plugin:react/recommended", "standard"],
"parser": "babel-eslint",
"plugins": [
"react",
"react-hooks"
],
"parserOptions": {
"ecmaFeatures": {
"jsx": true
}
},
"settings": {
"react": {
"version": "detect"
}
},
"rules": {
"array-bracket-spacing": ["error", "never"],
"block-scoped-var": "error",
"block-spacing": "error",
"brace-style": ["error", "1tbs", { "allowSingleLine": true }],
"camelcase": "error",
"comma-dangle": ["error", "never"],
"comma-spacing": ["error", { "before": false, "after": true }],
"comma-style": ["error", "last"],
"complexity": ["error", { "max": 25 }],
"default-case": "error",
"dot-notation": "error",
"eol-last": ["error", "always"],
"eqeqeq": ["error", "always"],
"func-call-spacing": ["error", "never"],
"func-name-matching": "error",
"func-style": ["error", "declaration", { "allowArrowFunctions": true }],
"indent": ["error", 2, { "SwitchCase": 1 }],
"jsx-quotes": ["error", "prefer-single"],
"key-spacing": [2, {
"singleLine": {
"beforeColon": false,
"afterColon": true
},
"multiLine": {
"beforeColon": false,
"afterColon": true
}
}],
"keyword-spacing": ["error", { "after": true, "before": true }],
"linebreak-style": ["error", "unix"],
"max-depth": ["error", 3],
"max-len": ["error", 120, {
"ignoreComments": true,
"ignoreUrls": true,
"ignoreStrings": true,
"ignoreTemplateLiterals": true,
"ignoreRegExpLiterals": true
}],
"max-nested-callbacks": ["error", 3],
"max-params": ["error", 4],
"new-cap": "off",
"newline-after-var": ["warn", "always"],
"newline-before-return": "error",
"newline-per-chained-call": ["error", { "ignoreChainWithDepth": 4 }],
"no-alert": "error",
"no-array-constructor": "error",
"no-class-assign": "error",
"no-console": "error",
"no-continue": "error",
"no-duplicate-imports": "error",
"no-eval": "error",
"no-extend-native": ["error", { "exceptions": ["Object"] }],
"no-extra-bind": "error",
"no-floating-decimal": "error",
"no-lonely-if": "error",
"no-multi-spaces": "error",
"no-multi-str": "error",
"no-multiple-empty-lines": ["error", { "max": 1, "maxEOF": 1 }],
"no-nested-ternary": "error",
"no-new-func": "error",
"no-new-object": "error",
"no-new-wrappers": "error",
"no-new": "warn",
"no-param-reassign": "error",
"no-proto": "error",
"no-return-assign": "error",
"no-self-compare": "error",
"no-template-curly-in-string": "error",
"no-throw-literal": "error",
"no-trailing-spaces": "error",
"no-undef-init": "error",
"no-unneeded-ternary": "error",
"no-unused-expressions": "error",
"no-use-before-define": "error",
"no-useless-constructor": "error",
"no-useless-rename": ["error", {"ignoreImport": true }],
"no-var": "error",
"no-void": "error",
"no-warning-comments": [1, {"terms": ["fixme"]}],
"no-whitespace-before-property": "error",
"object-curly-spacing": ["error", "always"],
"prefer-const": "error",
"prefer-promise-reject-errors": ["error", {"allowEmptyReject": true}],
"prefer-spread": "error",
"prefer-template": "error",
"quotes": ["error", "single", { "allowTemplateLiterals": true }],
"space-in-parens": ["error", "never"],
"spaced-comment": ["error", "always"],
"wrap-iife": ["error", "any"]
},
"globals": {
"Image": true,
"localStorage": true,
"XMLHttpRequest": true,
"browser": true,
"chai": true,
"should": true,
"it": true,
"skip": true,
"jest": true,
"jsdom": true,
"beforeAll": true,
"define": true,
"describe": true,
"beforeEach": true,
"afterEach": true,
"assert": true,
"before": true,
"expect": true,
"FileReader": true,
"FormData": true,
"DOMParser": true,
"Papa": true,
"ReactDOM": true,
"test": true,
"Blob": true,
"File": true,
"URL": true,
"fetch": true,
"XMLSerializer": true,
"Element": true
}
}