@mikey-pro/eslint-config 8.0.18 → 8.0.19
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 +15 -3
- package/package.json +1 -1
- package/rules.js +0 -4
package/index.js
CHANGED
|
@@ -4,7 +4,6 @@ import compatPlugin from 'eslint-plugin-compat';
|
|
|
4
4
|
import cssModules from 'eslint-plugin-css-modules';
|
|
5
5
|
import importPlugin from 'eslint-plugin-import';
|
|
6
6
|
import onlyWarn from 'eslint-plugin-only-warn';
|
|
7
|
-
import prettier from 'eslint-plugin-prettier';
|
|
8
7
|
import unicorn from 'eslint-plugin-unicorn';
|
|
9
8
|
import globals from 'globals';
|
|
10
9
|
import securityPlugin from 'eslint-plugin-security';
|
|
@@ -23,6 +22,7 @@ import boundariesPlugin from 'eslint-plugin-boundaries';
|
|
|
23
22
|
import nPlugin from 'eslint-plugin-n';
|
|
24
23
|
import radarPlugin from 'eslint-plugin-radar';
|
|
25
24
|
import optimizeRegexPlugin from 'eslint-plugin-optimize-regex';
|
|
25
|
+
import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended';
|
|
26
26
|
|
|
27
27
|
import { baseOverrides } from './overrides.js';
|
|
28
28
|
import { baseRules } from './rules.js';
|
|
@@ -49,6 +49,7 @@ const config = [
|
|
|
49
49
|
],
|
|
50
50
|
},
|
|
51
51
|
eslintJs.configs.recommended,
|
|
52
|
+
eslintPluginPrettierRecommended,
|
|
52
53
|
{
|
|
53
54
|
files: ['**/*.js', '**/*.jsx', '**/*.mjs', '**/*.cjs'], // Add files pattern
|
|
54
55
|
languageOptions: {
|
|
@@ -67,7 +68,6 @@ const config = [
|
|
|
67
68
|
reportUnusedDisableDirectives: true,
|
|
68
69
|
},
|
|
69
70
|
plugins: {
|
|
70
|
-
prettier,
|
|
71
71
|
unicorn,
|
|
72
72
|
'css-modules': cssModules,
|
|
73
73
|
'only-warn': onlyWarn,
|
|
@@ -147,7 +147,7 @@ const config = [
|
|
|
147
147
|
},
|
|
148
148
|
settings: {
|
|
149
149
|
'json/json-with-comments-files': [],
|
|
150
|
-
polyfills: ['Promise', 'fetch', 'URLSearchParams'],
|
|
150
|
+
polyfills: ['Promise', 'fetch', 'URLSearchParams', 'Array.prototype.includes'],
|
|
151
151
|
jest: {
|
|
152
152
|
version: 29,
|
|
153
153
|
},
|
|
@@ -160,6 +160,18 @@ const config = [
|
|
|
160
160
|
extensions: ['.js', '.jsx', '.ts', '.tsx', '.mjs', '.cjs']
|
|
161
161
|
}
|
|
162
162
|
},
|
|
163
|
+
boundaries: {
|
|
164
|
+
elements: [
|
|
165
|
+
{ type: 'app', pattern: 'app/*' },
|
|
166
|
+
{ type: 'pages', pattern: 'pages/*' },
|
|
167
|
+
{ type: 'components', pattern: 'components/*' },
|
|
168
|
+
{ type: 'hooks', pattern: 'hooks/*' },
|
|
169
|
+
{ type: 'utils', pattern: 'utils/*' },
|
|
170
|
+
{ type: 'services', pattern: 'services/*' },
|
|
171
|
+
{ type: 'types', pattern: 'types/*' },
|
|
172
|
+
{ type: 'config', pattern: 'config/*' }
|
|
173
|
+
]
|
|
174
|
+
}
|
|
163
175
|
},
|
|
164
176
|
},
|
|
165
177
|
...baseOverrides,
|
package/package.json
CHANGED
package/rules.js
CHANGED
|
@@ -218,8 +218,6 @@ export const baseRules = {
|
|
|
218
218
|
'regexp/no-missing-g-flag': 'error',
|
|
219
219
|
|
|
220
220
|
// Enhanced TypeScript
|
|
221
|
-
'etc/no-commented-out-code': 'warn',
|
|
222
|
-
'etc/no-implicit-any-catch': 'error',
|
|
223
221
|
'etc/prefer-interface': 'error',
|
|
224
222
|
|
|
225
223
|
// Enhanced Import Rules
|
|
@@ -268,8 +266,6 @@ export const baseRules = {
|
|
|
268
266
|
|
|
269
267
|
// Performance
|
|
270
268
|
'optimize-regex/optimize-regex': 'warn',
|
|
271
|
-
'radar/no-duplicate-string': ['warn', 5],
|
|
272
|
-
'radar/cognitive-complexity': ['error', 15],
|
|
273
269
|
|
|
274
270
|
// Enhanced Security
|
|
275
271
|
'n/no-unsupported-features/es-syntax': ['error', {
|