-
Notifications
You must be signed in to change notification settings - Fork 2
/
.eslintrc.yml
338 lines (333 loc) · 6.62 KB
/
.eslintrc.yml
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
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
# ESLint v8.0.1
parserOptions:
ecmaFeatures:
impliedStrict: true
ecmaVersion: latest
sourceType: module
extends:
- eslint:recommended
env:
es2021: true
reportUnusedDisableDirectives: true
rules:
accessor-pairs: warn
array-bracket-newline:
- warn
- multiline: true
array-bracket-spacing: error
array-callback-return: warn
arrow-body-style: warn
arrow-parens:
- error
- as-needed
arrow-spacing: error
block-scoped-var: warn
block-spacing: error
brace-style:
- warn
- 1tbs
- allowSingleLine: true
camelcase: warn
class-methods-use-this: off
comma-dangle:
- error
- always-multiline
comma-spacing: error
comma-style: error
computed-property-spacing: error
curly:
- error
- multi-line
- consistent
default-case: warn
default-case-last: warn
default-param-last: warn
dot-location:
- error
- property
dot-notation: error
eqeqeq: warn
eol-last: warn
func-call-spacing: error
func-name-matching: error
func-names:
- warn
- as-needed
function-paren-newline: error
generator-star-spacing: error
grouped-accessor-pairs:
- error
- getBeforeSet
implicit-arrow-linebreak: error
indent:
- error
- 2
- MemberExpression: 0
SwitchCase: 2
key-spacing:
- error
- align: value
mode: minimum
keyword-spacing: error
lines-around-comment: off
lines-between-class-members: warn
max-depth: warn
max-len:
- warn
- code: 120
ignoreComments: true
ignoreStrings: true
max-nested-callbacks:
- warn
- 3
max-params: warn
max-statements: off
max-statements-per-line:
- warn
- max: 2
new-cap: warn
newline-per-chained-call: warn
no-alert: off
no-array-constructor: warn
no-bitwise: warn
no-caller: error
no-confusing-arrow: warn
no-console:
- warn
- allow:
- error
- info
- time
- timeEnd
- warn
no-constructor-return: warn
no-duplicate-imports:
- warn
- includeExports: true
no-else-return: error
no-empty:
- error
- allowEmptyCatch: false
no-empty-function: error
no-eq-null: error
no-extend-native: warn
no-extra-bind: warn
no-extra-label: warn
no-extra-parens: warn
no-eval: warn
no-fallthrough:
- error
- commentPattern: /falls?\s?through/i
no-floating-decimal: error
no-implicit-coercion: warn
no-implicit-globals: warn
no-implied-eval: warn
no-invalid-this: warn
no-iterator: error
no-label-var: warn
no-lone-blocks: warn
no-lonely-if: warn
no-loop-func: warn
no-magic-numbers:
- warn
- ignoreArrayIndexes: true
ignoreDefaultValues: true
ignore:
- -1
- 0
- 1
- 2
- 60
- 200
- 201
- 204
- 207
- 302
- 304
- 400
- 401
- 403
- 404
- 405
- 408
- 409
- 410
- 412
- 413
- 422
- 429
- 449
- 500
- 503
no-mixed-operators: warn
no-multi-assign: warn
no-multi-spaces:
- error
- exceptions:
AssignmentExpression: true
AssignmentPattern: true
IfStatement: true
ImportDeclaration: true
ImportSpecifier: true
SwitchCase: true
VariableDeclaration: true
VariableDeclarator: true
ignoreEOLComments: true
no-multi-str: error
no-multiple-empty-lines: warn
no-negated-condition: warn
no-nested-ternary: warn
no-new: warn
no-new-func: warn
no-new-object: warn
no-new-wrappers: warn
no-octal-escape: error
no-param-reassign: warn
no-promise-executor-return: warn
no-proto: error
no-return-assign:
- warn
- always
no-return-await: warn
no-script-url: warn
no-self-compare: error
no-sequences: error
no-shadow:
- warn
- builtinGlobals: true
hoist: all
allow:
- cb
- done
- err
- error
- ev
- event
- name
- resolve
- reject
- test
- Text
no-tabs: warn
no-template-curly-in-string: warn
no-throw-literal: error
no-trailing-spaces: off
no-undef:
- error
- typeof: true
no-undef-init: error
no-undefined: warn
no-underscore-dangle:
- warn
- allow:
- __dirname
- _ts
- _etag
no-unmodified-loop-condition: warn
no-unneeded-ternary:
- error
- defaultAssignment: false
no-unreachable-loop: error
no-unused-expressions: error
no-use-before-define:
- warn
- classes: false
functions: false
no-useless-call: error
no-useless-computed-key: warn
no-useless-concat: warn
no-useless-constructor: warn
no-useless-rename: warn
no-useless-return: warn
no-var: warn
no-warning-comments: warn
no-whitespace-before-property: error
nonblock-statement-body-position: error
object-curly-newline:
- warn
- ObjectExpression:
consistent: true
minProperties: 4
ObjectPattern:
multiline: true
object-curly-spacing:
- error
- always
- objectsInObjects: true
object-property-newline:
- warn
- allowMultiplePropertiesPerLine: true
object-shorthand: warn
one-var:
- error
- never
operator-assignment: error
operator-linebreak: off
prefer-arrow-callback:
- error
- allowNamedFunctions: true
prefer-const: error
prefer-destructuring: warn
prefer-named-capture-group: warn
prefer-numeric-literals: warn
prefer-promise-reject-errors: warn
prefer-exponentiation-operator: warn
prefer-rest-params: warn
prefer-spread: warn
prefer-template: warn
quote-props:
- warn
- as-needed
quotes:
- error
- backtick
- allowTemplateLiterals: true
avoidEscape: true
require-atomic-updates: warn
require-await: warn
require-unicode-regexp: warn
rest-spread-spacing: error
semi: error
semi-spacing: error
semi-style: error
sort-imports:
- warn
- allowSeparatedGroups: true
ignoreCase: true
memberSyntaxSortOrder:
- none
- all
- single
- multiple
sort-keys:
- warn
- asc
- caseSensitive: false
natural: true
sort-vars: warn
space-before-blocks: error
space-before-function-paren:
- error
- anonymous: never
named: never
space-in-parens: error
space-infix-ops: error
space-unary-ops: error
spaced-comment:
- error
- always
- markers:
- '*'
switch-colon-spacing: error
symbol-description: error
template-curly-spacing:
- warn
- always
template-tag-spacing: error
unicode-bom: error
vars-on-top: warn
yield-star-spacing: error
yoda:
- warn
- never
- exceptRange: true