@wkovacs64/eslint-config 7.2.5 → 7.3.1
Sign up to get free protection for your applications and to get access to all the features.
- package/index.js +9 -7
- package/package.json +19 -19
package/index.js
CHANGED
@@ -31,7 +31,8 @@ const hasPlaywright = has('@playwright/test');
|
|
31
31
|
|
32
32
|
const vitestFiles = ['**/__tests__/**/*', '**/*.test.*'];
|
33
33
|
const testFiles = ['**/tests/**', '**/#tests/**', ...vitestFiles];
|
34
|
-
const
|
34
|
+
const allPlaywrightFiles = ['**/playwright/**'];
|
35
|
+
const playwrightTestFiles = ['**/playwright/**/*.spec.*'];
|
35
36
|
|
36
37
|
export const config = [
|
37
38
|
{
|
@@ -123,8 +124,9 @@ export const config = [
|
|
123
124
|
hasReact
|
124
125
|
? {
|
125
126
|
files: ['**/*.ts?(x)', '**/*.js?(x)'],
|
127
|
+
ignores: [...allPlaywrightFiles],
|
126
128
|
plugins: {
|
127
|
-
'react-hooks':
|
129
|
+
'react-hooks': (await import('eslint-plugin-react-hooks')).default,
|
128
130
|
},
|
129
131
|
rules: {
|
130
132
|
'react-hooks/rules-of-hooks': ERROR,
|
@@ -288,7 +290,7 @@ export const config = [
|
|
288
290
|
hasTestingLibrary
|
289
291
|
? {
|
290
292
|
files: testFiles,
|
291
|
-
ignores: [...
|
293
|
+
ignores: [...playwrightTestFiles],
|
292
294
|
plugins: {
|
293
295
|
'testing-library': fixupPluginRules(
|
294
296
|
(await import('eslint-plugin-testing-library')).default,
|
@@ -328,7 +330,7 @@ export const config = [
|
|
328
330
|
hasJestDom
|
329
331
|
? {
|
330
332
|
files: testFiles,
|
331
|
-
ignores: [...
|
333
|
+
ignores: [...playwrightTestFiles],
|
332
334
|
plugins: {
|
333
335
|
'jest-dom': (await import('eslint-plugin-jest-dom')).default,
|
334
336
|
},
|
@@ -351,9 +353,9 @@ export const config = [
|
|
351
353
|
hasVitest
|
352
354
|
? {
|
353
355
|
files: testFiles,
|
354
|
-
ignores: [...
|
356
|
+
ignores: [...playwrightTestFiles],
|
355
357
|
plugins: {
|
356
|
-
vitest: (await import('eslint-plugin
|
358
|
+
vitest: (await import('@vitest/eslint-plugin')).default,
|
357
359
|
},
|
358
360
|
rules: {
|
359
361
|
// you don't want the editor to autofix this, but we do want to be
|
@@ -365,7 +367,7 @@ export const config = [
|
|
365
367
|
|
366
368
|
hasPlaywright
|
367
369
|
? {
|
368
|
-
files:
|
370
|
+
files: playwrightTestFiles,
|
369
371
|
...playwright.configs['flat/recommended'],
|
370
372
|
}
|
371
373
|
: null,
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@wkovacs64/eslint-config",
|
3
|
-
"version": "7.
|
3
|
+
"version": "7.3.1",
|
4
4
|
"description": "@wKovacs64 ESLint config",
|
5
5
|
"keywords": [
|
6
6
|
"eslint",
|
@@ -50,29 +50,29 @@
|
|
50
50
|
"node": "^18.18.0 || >=20.0.0"
|
51
51
|
},
|
52
52
|
"dependencies": {
|
53
|
-
"@eslint/compat": "
|
54
|
-
"@eslint/js": "^9.
|
55
|
-
"eslint-plugin-import-x": "^
|
53
|
+
"@eslint/compat": "~1.1.1",
|
54
|
+
"@eslint/js": "^9.15.0",
|
55
|
+
"eslint-plugin-import-x": "^4.4.2",
|
56
56
|
"eslint-plugin-jest-dom": "^5.4.0",
|
57
|
-
"eslint-plugin-jsx-a11y": "^6.
|
58
|
-
"eslint-plugin-playwright": "^
|
59
|
-
"eslint-plugin-react": "^7.
|
60
|
-
"eslint-plugin-react-hooks": "^
|
61
|
-
"eslint-plugin-testing-library": "^6.
|
62
|
-
"eslint-plugin
|
63
|
-
"globals": "^15.
|
64
|
-
"typescript-eslint": "^8.
|
57
|
+
"eslint-plugin-jsx-a11y": "^6.10.2",
|
58
|
+
"eslint-plugin-playwright": "^2.0.1",
|
59
|
+
"eslint-plugin-react": "^7.37.2",
|
60
|
+
"eslint-plugin-react-hooks": "^5.0.0",
|
61
|
+
"eslint-plugin-testing-library": "^6.4.0",
|
62
|
+
"@vitest/eslint-plugin": "^1.1.10",
|
63
|
+
"globals": "^15.12.0",
|
64
|
+
"typescript-eslint": "^8.14.0"
|
65
65
|
},
|
66
66
|
"devDependencies": {
|
67
67
|
"@changesets/changelog-github": "0.5.0",
|
68
|
-
"@changesets/cli": "2.27.
|
68
|
+
"@changesets/cli": "2.27.9",
|
69
69
|
"@types/eslint__js": "8.42.3",
|
70
|
-
"@types/node": "
|
71
|
-
"@types/react": "18.3.
|
72
|
-
"@types/react-dom": "18.3.
|
70
|
+
"@types/node": "22.9.0",
|
71
|
+
"@types/react": "18.3.12",
|
72
|
+
"@types/react-dom": "18.3.1",
|
73
73
|
"@wkovacs64/prettier-config": "4.1.1",
|
74
|
-
"eslint": "8.57.
|
75
|
-
"prettier": "3.3.
|
76
|
-
"typescript": "5.
|
74
|
+
"eslint": "8.57.1",
|
75
|
+
"prettier": "3.3.3",
|
76
|
+
"typescript": "5.6.3"
|
77
77
|
}
|
78
78
|
}
|