-
Notifications
You must be signed in to change notification settings - Fork 12
/
.eslintrc.json
87 lines (83 loc) · 2.65 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
{
"env": {
"browser": true,
"node": true,
"commonjs": true,
"es2021": true
},
"extends": ["eslint:recommended", "plugin:node/recommended"],
"plugins": ["node"],
"parserOptions": {
"ecmaVersion": 2022
},
"globals": {
"node": false
},
"rules": {
"node/no-unpublished-require": "off",
"no-unused-vars": "warn",
"indent": ["error", 2],
"linebreak-style": ["error", "unix"],
"quotes": [
"error",
"single",
{
"avoidEscape": true,
"allowTemplateLiterals": true
}
],
"semi": ["error", "always"],
"array-bracket-spacing": ["error", "never"],
"block-spacing": ["error", "never"],
"brace-style": "error",
"camelcase": "error",
"comma-spacing": [
"error",
{
"before": false,
"after": true
}
],
"comma-style": ["error", "last"],
"computed-property-spacing": ["error", "never"],
"eol-last": "error",
"key-spacing": ["error", {"beforeColon": false, "afterColon": true}],
"no-lonely-if": "error",
"no-multiple-empty-lines": ["error", {"max": 1}],
"no-nested-ternary": "error",
"func-call-spacing": ["error", "never"],
"no-trailing-spaces": "error",
"no-unneeded-ternary": "error",
"object-curly-spacing": ["error", "never"],
"operator-linebreak": ["error", "after"],
"semi-spacing": "error",
"keyword-spacing": ["error", { "after": true }],
"space-before-blocks": "error",
"space-before-function-paren": ["error", "never"],
"space-in-parens": ["error", "never"],
"space-infix-ops": "error",
"space-unary-ops": "error",
"spaced-comment": ["error", "always"],
"no-empty-character-class": "error",
"no-extra-boolean-cast": "error",
"arrow-spacing": "error",
"no-var": "error",
"prefer-arrow-callback": "error",
"prefer-const": "warn",
"prefer-template": "error",
"consistent-return": "error",
"dot-notation": "error",
"eqeqeq": ["error", "smart"],
"no-else-return": "error",
"no-floating-decimal": "error",
"no-implicit-coercion": "error",
"no-loop-func": "error",
"no-multi-spaces": "error",
"no-new": "error",
"no-octal-escape": "error",
"no-return-assign": ["error", "always"],
"no-self-compare": "error",
"no-useless-concat": "error",
"yoda": "error"
}
}