@lidofinance/eslint-config 0.0.2 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +14 -0
- package/README.md +4 -3
- package/all-hard.js +10 -10
- package/all.js +10 -10
- package/auto-hard.js +4 -4
- package/auto.js +4 -4
- package/lib/build-config.js +215 -200
- package/lib/env.js +53 -22
- package/package.json +42 -34
- package/prettier.js +15 -0
- package/rulesets/easy.js +205 -203
- package/rulesets/hard.js +70 -70
- package/.eslintrc +0 -12
package/rulesets/hard.js
CHANGED
|
@@ -1,72 +1,72 @@
|
|
|
1
|
-
const { nextRules, tsRules, reactRules, defaultRules } = require(
|
|
1
|
+
const { nextRules, tsRules, reactRules, defaultRules } = require("./easy");
|
|
2
2
|
|
|
3
3
|
module.exports = {
|
|
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
|
-
}
|
|
4
|
+
nextRules: {
|
|
5
|
+
...nextRules,
|
|
6
|
+
},
|
|
7
|
+
tsRules,
|
|
8
|
+
reactRules: {
|
|
9
|
+
...reactRules,
|
|
10
|
+
"react/prop-types": "error",
|
|
11
|
+
},
|
|
12
|
+
defaultRules: {
|
|
13
|
+
...defaultRules,
|
|
14
|
+
"promise/always-return": "error",
|
|
15
|
+
"promise/catch-or-return": "error",
|
|
16
|
+
"promise/no-native": "off",
|
|
17
|
+
"promise/no-nesting": "warn",
|
|
18
|
+
"promise/no-promise-in-callback": "warn",
|
|
19
|
+
"promise/no-callback-in-promise": "warn",
|
|
20
|
+
"promise/no-new-statics": "error",
|
|
21
|
+
"promise/no-return-in-finally": "warn",
|
|
22
|
+
"promise/valid-params": "warn",
|
|
23
|
+
"import/no-named-as-default": "warn",
|
|
24
|
+
"import/no-named-as-default-member": "warn",
|
|
25
|
+
"import/no-duplicates": "warn",
|
|
26
|
+
"sonarjs/cognitive-complexity": "warn",
|
|
27
|
+
"sonarjs/prefer-immediate-return": "error",
|
|
28
|
+
"unicorn/consistent-destructuring": "error",
|
|
29
|
+
"unicorn/custom-error-definition": "error",
|
|
30
|
+
"unicorn/no-abusive-eslint-disable": "error",
|
|
31
|
+
"no-nested-ternary": "error",
|
|
32
|
+
"unicorn/no-unsafe-regex": "error",
|
|
33
|
+
"unicorn/no-unused-properties": "error",
|
|
34
|
+
"unicorn/no-useless-fallback-in-spread": "error",
|
|
35
|
+
"unicorn/numeric-separators-style": "warn",
|
|
36
|
+
"unicorn/prefer-at": "warn",
|
|
37
|
+
"unicorn/prefer-code-point": "warn",
|
|
38
|
+
"unicorn/prefer-date-now": "warn",
|
|
39
|
+
"unicorn/prefer-default-parameters": "warn",
|
|
40
|
+
"unicorn/prefer-dom-node-append": "warn",
|
|
41
|
+
"unicorn/prefer-dom-node-dataset": "warn",
|
|
42
|
+
"unicorn/prefer-dom-node-remove": "warn",
|
|
43
|
+
"unicorn/prefer-dom-node-text-content": "warn",
|
|
44
|
+
"unicorn/prefer-export-from": "warn",
|
|
45
|
+
"unicorn/prefer-includes": "warn",
|
|
46
|
+
"unicorn/prefer-json-parse-buffer": "warn",
|
|
47
|
+
"unicorn/prefer-keyboard-event-key": "warn",
|
|
48
|
+
"unicorn/prefer-math-trunc": "warn",
|
|
49
|
+
"unicorn/prefer-modern-dom-apis": "warn",
|
|
50
|
+
"unicorn/prefer-modern-math-apis": "warn",
|
|
51
|
+
"unicorn/prefer-native-coercion-functions": "warn",
|
|
52
|
+
"unicorn/prefer-negative-index": "warn",
|
|
53
|
+
"unicorn/prefer-number-properties": "warn",
|
|
54
|
+
"unicorn/prefer-object-from-entries": "warn",
|
|
55
|
+
"unicorn/prefer-optional-catch-binding": "warn",
|
|
56
|
+
"unicorn/prefer-prototype-methods": "warn",
|
|
57
|
+
"unicorn/prefer-query-selector": "warn",
|
|
58
|
+
"unicorn/prefer-reflect-apply": "warn",
|
|
59
|
+
"unicorn/prefer-regexp-test": "warn",
|
|
60
|
+
"unicorn/prefer-set-has": "warn",
|
|
61
|
+
"unicorn/prefer-spread": "warn",
|
|
62
|
+
"unicorn/prefer-string-replace-all": "warn",
|
|
63
|
+
"unicorn/prefer-string-slice": "warn",
|
|
64
|
+
"unicorn/prefer-string-starts-ends-with": "warn",
|
|
65
|
+
"unicorn/prefer-string-trim-start-end": "warn",
|
|
66
|
+
"unicorn/prefer-switch": "warn",
|
|
67
|
+
"unicorn/prefer-ternary": "warn",
|
|
68
|
+
"unicorn/prefer-top-level-await": "warn",
|
|
69
|
+
"unicorn/prefer-type-error": "warn",
|
|
70
|
+
"unicorn/string-content": "error",
|
|
71
|
+
},
|
|
72
|
+
};
|