-
Notifications
You must be signed in to change notification settings - Fork 295
/
.eslintrc.js
56 lines (55 loc) · 1.43 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
const OK = "off";
const _W = "warn";
const E = "error";
module.exports = {
root: true,
extends: "eslint:recommended",
env: {
node: true,
browser: true,
es2021: true
},
parserOptions: {
ecmaVersion: "latest",
sourceType: "module"
},
rules: {
"prefer-const": [OK],
"no-constant-condition": [OK],
"no-useless-escape": [OK],
"no-inner-declarations": [OK],
"strict": [E, "global"],
"no-undef": [E],
"no-unused-vars": [E, {"varsIgnorePattern": "^_", "argsIgnorePattern": "^_"}],
"yoda": [E],
"semi": [E, "always"],
"linebreak-style": [E, "unix"],
"no-trailing-spaces": [E],
"no-tabs": [E],
"no-var": [E],
"no-implicit-globals": [E],
"space-infix-ops": [E],
"space-unary-ops": [E],
"arrow-spacing": [E],
"arrow-parens": [E],
"space-before-blocks": [E],
"comma-spacing": [E],
"func-call-spacing": [E],
"computed-property-spacing": [E],
"key-spacing": [E],
"keyword-spacing": [E],
"no-multi-spaces": [E],
"no-multiple-empty-lines": [E, {max: 1, maxBOF: 0, maxEOF: 0}],
"brace-style": [E, "1tbs"],
"curly": [E, "all"],
"rest-spread-spacing": [E],
"semi-spacing": [E],
"switch-colon-spacing": [E],
"one-var": [E, "never"],
"padding-line-between-statements": [
E,
{"blankLine": "always", "prev": "*", "next": "function"},
{"blankLine": "always", "prev": "function", "next": "*"},
],
},
};