@perfective/eslint-config 0.22.0 → 0.23.1
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/index.js +3 -0
- package/package.json +19 -18
- package/rules/eslint/possible-problems.js +2 -0
- package/rules/eslint/suggestions.js +3 -5
- package/rules/jest/index.js +3 -0
- package/rules/testing-library/index.js +2 -1
- package/rules/typescript-eslint/extension-rules.js +2 -0
- package/rules/typescript-eslint/supported-rules.js +4 -1
package/index.js
CHANGED
|
@@ -99,6 +99,9 @@ module.exports = {
|
|
|
99
99
|
rules: {
|
|
100
100
|
'@typescript-eslint/ban-ts-comment': ['error', {
|
|
101
101
|
'ts-expect-error': 'allow-with-description',
|
|
102
|
+
'ts-ignore': true,
|
|
103
|
+
'ts-nocheck': true,
|
|
104
|
+
'ts-check': false,
|
|
102
105
|
}],
|
|
103
106
|
'@typescript-eslint/init-declarations': 'off',
|
|
104
107
|
'@typescript-eslint/unbound-method': 'off',
|
package/package.json
CHANGED
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@perfective/eslint-config",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.23.1",
|
|
4
4
|
"description": "ESLint shareable rules configuration",
|
|
5
5
|
"keywords": ["code quality", "code standard", "code style", "eslint", "eslint config", "lint", "perfective", "tslint", "tslint config", "typescript"],
|
|
6
6
|
"author": "Andrey Mikheychik <a.mikheychik@gmail.com>",
|
|
7
7
|
"homepage": "https://github.com/perfective/eslint-config",
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
|
-
"url": "https://github.com/perfective/eslint-config.git"
|
|
10
|
+
"url": "git+https://github.com/perfective/eslint-config.git"
|
|
11
11
|
},
|
|
12
12
|
"license": "MIT",
|
|
13
13
|
"peerDependencies": {
|
|
14
|
-
"@babel/eslint-parser": "^7.
|
|
15
|
-
"@typescript-eslint/eslint-plugin": "^6.
|
|
16
|
-
"@typescript-eslint/eslint-plugin-tslint": "^6.
|
|
17
|
-
"@typescript-eslint/parser": "^6.
|
|
18
|
-
"eslint": "^8.
|
|
19
|
-
"eslint-import-resolver-typescript": "^3.6.
|
|
20
|
-
"eslint-plugin-array-func": "^
|
|
21
|
-
"eslint-plugin-cypress": "^2.
|
|
22
|
-
"eslint-plugin-deprecation": "^
|
|
14
|
+
"@babel/eslint-parser": "^7.23.3",
|
|
15
|
+
"@typescript-eslint/eslint-plugin": "^6.12.0",
|
|
16
|
+
"@typescript-eslint/eslint-plugin-tslint": "^6.12.0",
|
|
17
|
+
"@typescript-eslint/parser": "^6.12.0",
|
|
18
|
+
"eslint": "^8.54.0",
|
|
19
|
+
"eslint-import-resolver-typescript": "^3.6.1",
|
|
20
|
+
"eslint-plugin-array-func": "^4.0.0",
|
|
21
|
+
"eslint-plugin-cypress": "^2.15.1",
|
|
22
|
+
"eslint-plugin-deprecation": "^2.0.0",
|
|
23
23
|
"eslint-plugin-eslint-comments": "^3.2.0",
|
|
24
|
-
"eslint-plugin-import": "^2.
|
|
25
|
-
"eslint-plugin-jest": "^27.
|
|
24
|
+
"eslint-plugin-import": "^2.29.0",
|
|
25
|
+
"eslint-plugin-jest": "^27.6.0",
|
|
26
26
|
"eslint-plugin-jest-dom": "^5.1.0",
|
|
27
27
|
"eslint-plugin-jest-formatting": "^3.1.0",
|
|
28
|
-
"eslint-plugin-jsdoc": "^46.
|
|
28
|
+
"eslint-plugin-jsdoc": "^46.9.0",
|
|
29
29
|
"eslint-plugin-node": "^11.1.0",
|
|
30
30
|
"eslint-plugin-prefer-arrow": "^1.2.3",
|
|
31
31
|
"eslint-plugin-promise": "^6.1.1",
|
|
32
32
|
"eslint-plugin-rxjs": "^5.0.3",
|
|
33
33
|
"eslint-plugin-simple-import-sort": "^10.0.0",
|
|
34
|
-
"eslint-plugin-sonarjs": "^0.
|
|
35
|
-
"eslint-plugin-testing-library": "^6.0
|
|
36
|
-
"eslint-plugin-unicorn": "^
|
|
34
|
+
"eslint-plugin-sonarjs": "^0.23.0",
|
|
35
|
+
"eslint-plugin-testing-library": "^6.2.0",
|
|
36
|
+
"eslint-plugin-unicorn": "^49.0.0",
|
|
37
37
|
"tslint": "^6.1.3"
|
|
38
38
|
},
|
|
39
39
|
"peerDependenciesMeta": {
|
|
@@ -76,5 +76,6 @@
|
|
|
76
76
|
"require": "./rules.js",
|
|
77
77
|
"types": "./rules.d.ts"
|
|
78
78
|
}
|
|
79
|
-
}
|
|
79
|
+
},
|
|
80
|
+
"scripts": {}
|
|
80
81
|
}
|
|
@@ -111,9 +111,10 @@ module.exports = {
|
|
|
111
111
|
'no-nested-ternary': 'error',
|
|
112
112
|
'no-new': 'error',
|
|
113
113
|
'no-new-func': 'error',
|
|
114
|
-
'no-new-object': '
|
|
114
|
+
'no-new-object': 'off',
|
|
115
115
|
'no-new-wrappers': 'error',
|
|
116
116
|
'no-nonoctal-decimal-escape': 'error',
|
|
117
|
+
'no-object-constructor': 'error',
|
|
117
118
|
'no-octal': 'error',
|
|
118
119
|
'no-octal-escape': 'error',
|
|
119
120
|
'no-param-reassign': 'error',
|
|
@@ -166,10 +167,7 @@ module.exports = {
|
|
|
166
167
|
'operator-assignment': ['warn', 'always'],
|
|
167
168
|
'prefer-arrow-callback': 'warn',
|
|
168
169
|
'prefer-const': 'warn',
|
|
169
|
-
'prefer-destructuring':
|
|
170
|
-
object: false,
|
|
171
|
-
array: false,
|
|
172
|
-
}],
|
|
170
|
+
'prefer-destructuring': 'off',
|
|
173
171
|
'prefer-exponentiation-operator': 'warn',
|
|
174
172
|
'prefer-named-capture-group': 'off',
|
|
175
173
|
'prefer-numeric-literals': 'warn',
|
package/rules/jest/index.js
CHANGED
|
@@ -25,6 +25,7 @@ module.exports = {
|
|
|
25
25
|
'jest/no-commented-out-tests': 'error',
|
|
26
26
|
'jest/no-conditional-expect': 'error',
|
|
27
27
|
'jest/no-conditional-in-test': 'error',
|
|
28
|
+
'jest/no-confusing-set-timeout': 'error',
|
|
28
29
|
'jest/no-deprecated-functions': 'warn',
|
|
29
30
|
'jest/no-disabled-tests': 'error',
|
|
30
31
|
'jest/no-done-callback': 'error',
|
|
@@ -80,6 +81,8 @@ module.exports = {
|
|
|
80
81
|
'jest/valid-expect': 'error',
|
|
81
82
|
'jest/valid-title': ['warn', {
|
|
82
83
|
ignoreTypeOfDescribeName: true,
|
|
84
|
+
ignoreTypeOfTestName: false,
|
|
85
|
+
ignoreSpaces: false,
|
|
83
86
|
}],
|
|
84
87
|
},
|
|
85
88
|
};
|
|
@@ -25,8 +25,9 @@ module.exports = {
|
|
|
25
25
|
'testing-library/no-wait-for-multiple-assertions': 'error',
|
|
26
26
|
'testing-library/no-wait-for-side-effects': 'error',
|
|
27
27
|
'testing-library/no-wait-for-snapshot': 'error',
|
|
28
|
-
'testing-library/prefer-explicit-assert': '
|
|
28
|
+
'testing-library/prefer-explicit-assert': 'off',
|
|
29
29
|
'testing-library/prefer-find-by': 'warn',
|
|
30
|
+
'testing-library/prefer-implicit-assert': 'error',
|
|
30
31
|
'testing-library/prefer-presence-queries': ['error', {
|
|
31
32
|
presence: true,
|
|
32
33
|
absence: true,
|
|
@@ -147,6 +147,8 @@ module.exports = {
|
|
|
147
147
|
}],
|
|
148
148
|
'padding-line-between-statements': 'off',
|
|
149
149
|
'@typescript-eslint/padding-line-between-statements': 'off',
|
|
150
|
+
'prefer-destructuring': 'off',
|
|
151
|
+
'@typescript-eslint/prefer-destructuring': 'off',
|
|
150
152
|
'quotes': 'off',
|
|
151
153
|
'@typescript-eslint/quotes': ['warn', 'single', {
|
|
152
154
|
avoidEscape: true,
|
|
@@ -184,6 +184,7 @@ module.exports = {
|
|
|
184
184
|
'@typescript-eslint/no-unsafe-enum-comparison': 'error',
|
|
185
185
|
'@typescript-eslint/no-unsafe-member-access': 'error',
|
|
186
186
|
'@typescript-eslint/no-unsafe-return': 'error',
|
|
187
|
+
'@typescript-eslint/no-unsafe-unary-minus': 'error',
|
|
187
188
|
'@typescript-eslint/no-useless-empty-export': 'warn',
|
|
188
189
|
'@typescript-eslint/no-var-requires': 'error',
|
|
189
190
|
'@typescript-eslint/non-nullable-type-assertion-style': 'error',
|
|
@@ -259,7 +260,9 @@ module.exports = {
|
|
|
259
260
|
allowNullableNumber: false,
|
|
260
261
|
allowAny: false,
|
|
261
262
|
}],
|
|
262
|
-
'@typescript-eslint/switch-exhaustiveness-check': 'error',
|
|
263
|
+
'@typescript-eslint/switch-exhaustiveness-check': ['error', {
|
|
264
|
+
requireDefaultForNonUnion: true,
|
|
265
|
+
}],
|
|
263
266
|
'@typescript-eslint/triple-slash-reference': ['error', {
|
|
264
267
|
path: 'never',
|
|
265
268
|
types: 'always',
|