-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc
86 lines (86 loc) · 2.27 KB
/
.eslintrc
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
{
"extends": "./node_modules/@viewar/config-eslint/env/react",
"parser": "babel-eslint",
"parserOptions": {
"sourceType": "module",
"ecmaVersion": "2021",
"ecmaFeatures": {
"jsx": true,
"modules": true
}
},
"rules": {
"indent": ["error", 4],
"no-multi-spaces": [
"error",
{
"exceptions": {
"VariableDeclarator": true,
"ImportDeclaration": true,
"AssignmentExpression": true,
"ClassProperty": true
}
}
],
"key-spacing": [
"error",
{
"multiLine": {
"beforeColon": false,
"afterColon": true
},
"align": {
"mode": "minimum",
"on": "value"
}
}
],
"no-multiple-empty-lines": [
2,
{
"max": 2
}
],
"semi": ["error", "never"],
"one-var": [
"error",
{
"const": "never",
"var": "consecutive",
"let": "consecutive",
"separateRequires": true
}
],
"linebreak-style": 0,
"arrow-parens": [
"error",
"as-needed",
{
"requireForBlockBody": true
}
],
"no-param-reassign": "warn",
"no-console": "warn",
"no-unused-vars": "warn",
"padded-blocks": 0,
"object-curly-spacing": ["error", "never"],
"comma-dangle": ["error", "only-multiline"],
// ES6 rules
// These rules are only relevant to ES6 environments and are off by default.
"no-var": 2, // require let or const instead of var (off by default)
"import/no-extraneous-dependencies": [
"error",
{
"devDependencies": true,
"optionalDependencies": false,
"peerDependencies": false
}
],
// ABSS Keep it simple! tip: turn off word-wrap!
"max-depth": [1, 3], // specify the maximum depth that blocks can be nested (off by default)
"max-len": [2, 255, 2], // specify the maximum length of a line in your program (off by default)
"max-params": [2, 7], // limits the number of parameters that can be used in the function declaration. (off by default)
"max-statements": 0, // specify the maximum number of statement allowed in a function (off by default)
"no-bitwise": 0 // disallow use of bitwise operators (off by default)
}
}