@kouts/eslint-config 1.3.23 → 2.0.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.
Files changed (3) hide show
  1. package/dist/index.cjs +333 -336
  2. package/dist/index.js +333 -336
  3. package/package.json +11 -12
package/dist/index.js CHANGED
@@ -1,6 +1,5 @@
1
1
  import pluginVitest from '@vitest/eslint-plugin';
2
2
  import pluginHtml from 'eslint-plugin-html';
3
- import pluginImport from 'eslint-plugin-import-x';
4
3
  import pluginPrettier from 'eslint-plugin-prettier/recommended';
5
4
  import pluginSimpleImportSort from 'eslint-plugin-simple-import-sort';
6
5
  import neostandard, { plugins, resolveIgnoresFromGitignore } from 'neostandard';
@@ -12,7 +11,7 @@ function getDefaultExportFromCjs (x) {
12
11
  }
13
12
 
14
13
  var name = "@eslint/js";
15
- var version$1 = "9.15.0";
14
+ var version = "9.17.0";
16
15
  var description = "ESLint JavaScript language implementation";
17
16
  var main = "./src/index.js";
18
17
  var types = "./types/index.d.ts";
@@ -46,7 +45,7 @@ var engines = {
46
45
  };
47
46
  var require$$0 = {
48
47
  name: name,
49
- version: version$1,
48
+ version: version,
50
49
  description: description,
51
50
  main: main,
52
51
  types: types,
@@ -66,217 +65,226 @@ var require$$0 = {
66
65
  * script. Do not edit manually.
67
66
  */
68
67
 
69
- /* eslint quote-props: off -- autogenerated so don't lint */
68
+ var eslintAll;
69
+ var hasRequiredEslintAll;
70
70
 
71
- /*
72
- * IMPORTANT!
73
- *
74
- * We cannot add a "name" property to this object because it's still used in eslintrc
75
- * which doesn't support the "name" property. If we add a "name" property, it will
76
- * cause an error.
77
- */
71
+ function requireEslintAll () {
72
+ if (hasRequiredEslintAll) return eslintAll;
73
+ hasRequiredEslintAll = 1;
78
74
 
79
- var eslintAll = Object.freeze({
80
- "rules": {
81
- "accessor-pairs": "error",
82
- "array-callback-return": "error",
83
- "arrow-body-style": "error",
84
- "block-scoped-var": "error",
85
- "camelcase": "error",
86
- "capitalized-comments": "error",
87
- "class-methods-use-this": "error",
88
- "complexity": "error",
89
- "consistent-return": "error",
90
- "consistent-this": "error",
91
- "constructor-super": "error",
92
- "curly": "error",
93
- "default-case": "error",
94
- "default-case-last": "error",
95
- "default-param-last": "error",
96
- "dot-notation": "error",
97
- "eqeqeq": "error",
98
- "for-direction": "error",
99
- "func-name-matching": "error",
100
- "func-names": "error",
101
- "func-style": "error",
102
- "getter-return": "error",
103
- "grouped-accessor-pairs": "error",
104
- "guard-for-in": "error",
105
- "id-denylist": "error",
106
- "id-length": "error",
107
- "id-match": "error",
108
- "init-declarations": "error",
109
- "logical-assignment-operators": "error",
110
- "max-classes-per-file": "error",
111
- "max-depth": "error",
112
- "max-lines": "error",
113
- "max-lines-per-function": "error",
114
- "max-nested-callbacks": "error",
115
- "max-params": "error",
116
- "max-statements": "error",
117
- "new-cap": "error",
118
- "no-alert": "error",
119
- "no-array-constructor": "error",
120
- "no-async-promise-executor": "error",
121
- "no-await-in-loop": "error",
122
- "no-bitwise": "error",
123
- "no-caller": "error",
124
- "no-case-declarations": "error",
125
- "no-class-assign": "error",
126
- "no-compare-neg-zero": "error",
127
- "no-cond-assign": "error",
128
- "no-console": "error",
129
- "no-const-assign": "error",
130
- "no-constant-binary-expression": "error",
131
- "no-constant-condition": "error",
132
- "no-constructor-return": "error",
133
- "no-continue": "error",
134
- "no-control-regex": "error",
135
- "no-debugger": "error",
136
- "no-delete-var": "error",
137
- "no-div-regex": "error",
138
- "no-dupe-args": "error",
139
- "no-dupe-class-members": "error",
140
- "no-dupe-else-if": "error",
141
- "no-dupe-keys": "error",
142
- "no-duplicate-case": "error",
143
- "no-duplicate-imports": "error",
144
- "no-else-return": "error",
145
- "no-empty": "error",
146
- "no-empty-character-class": "error",
147
- "no-empty-function": "error",
148
- "no-empty-pattern": "error",
149
- "no-empty-static-block": "error",
150
- "no-eq-null": "error",
151
- "no-eval": "error",
152
- "no-ex-assign": "error",
153
- "no-extend-native": "error",
154
- "no-extra-bind": "error",
155
- "no-extra-boolean-cast": "error",
156
- "no-extra-label": "error",
157
- "no-fallthrough": "error",
158
- "no-func-assign": "error",
159
- "no-global-assign": "error",
160
- "no-implicit-coercion": "error",
161
- "no-implicit-globals": "error",
162
- "no-implied-eval": "error",
163
- "no-import-assign": "error",
164
- "no-inline-comments": "error",
165
- "no-inner-declarations": "error",
166
- "no-invalid-regexp": "error",
167
- "no-invalid-this": "error",
168
- "no-irregular-whitespace": "error",
169
- "no-iterator": "error",
170
- "no-label-var": "error",
171
- "no-labels": "error",
172
- "no-lone-blocks": "error",
173
- "no-lonely-if": "error",
174
- "no-loop-func": "error",
175
- "no-loss-of-precision": "error",
176
- "no-magic-numbers": "error",
177
- "no-misleading-character-class": "error",
178
- "no-multi-assign": "error",
179
- "no-multi-str": "error",
180
- "no-negated-condition": "error",
181
- "no-nested-ternary": "error",
182
- "no-new": "error",
183
- "no-new-func": "error",
184
- "no-new-native-nonconstructor": "error",
185
- "no-new-wrappers": "error",
186
- "no-nonoctal-decimal-escape": "error",
187
- "no-obj-calls": "error",
188
- "no-object-constructor": "error",
189
- "no-octal": "error",
190
- "no-octal-escape": "error",
191
- "no-param-reassign": "error",
192
- "no-plusplus": "error",
193
- "no-promise-executor-return": "error",
194
- "no-proto": "error",
195
- "no-prototype-builtins": "error",
196
- "no-redeclare": "error",
197
- "no-regex-spaces": "error",
198
- "no-restricted-exports": "error",
199
- "no-restricted-globals": "error",
200
- "no-restricted-imports": "error",
201
- "no-restricted-properties": "error",
202
- "no-restricted-syntax": "error",
203
- "no-return-assign": "error",
204
- "no-script-url": "error",
205
- "no-self-assign": "error",
206
- "no-self-compare": "error",
207
- "no-sequences": "error",
208
- "no-setter-return": "error",
209
- "no-shadow": "error",
210
- "no-shadow-restricted-names": "error",
211
- "no-sparse-arrays": "error",
212
- "no-template-curly-in-string": "error",
213
- "no-ternary": "error",
214
- "no-this-before-super": "error",
215
- "no-throw-literal": "error",
216
- "no-undef": "error",
217
- "no-undef-init": "error",
218
- "no-undefined": "error",
219
- "no-underscore-dangle": "error",
220
- "no-unexpected-multiline": "error",
221
- "no-unmodified-loop-condition": "error",
222
- "no-unneeded-ternary": "error",
223
- "no-unreachable": "error",
224
- "no-unreachable-loop": "error",
225
- "no-unsafe-finally": "error",
226
- "no-unsafe-negation": "error",
227
- "no-unsafe-optional-chaining": "error",
228
- "no-unused-expressions": "error",
229
- "no-unused-labels": "error",
230
- "no-unused-private-class-members": "error",
231
- "no-unused-vars": "error",
232
- "no-use-before-define": "error",
233
- "no-useless-assignment": "error",
234
- "no-useless-backreference": "error",
235
- "no-useless-call": "error",
236
- "no-useless-catch": "error",
237
- "no-useless-computed-key": "error",
238
- "no-useless-concat": "error",
239
- "no-useless-constructor": "error",
240
- "no-useless-escape": "error",
241
- "no-useless-rename": "error",
242
- "no-useless-return": "error",
243
- "no-var": "error",
244
- "no-void": "error",
245
- "no-warning-comments": "error",
246
- "no-with": "error",
247
- "object-shorthand": "error",
248
- "one-var": "error",
249
- "operator-assignment": "error",
250
- "prefer-arrow-callback": "error",
251
- "prefer-const": "error",
252
- "prefer-destructuring": "error",
253
- "prefer-exponentiation-operator": "error",
254
- "prefer-named-capture-group": "error",
255
- "prefer-numeric-literals": "error",
256
- "prefer-object-has-own": "error",
257
- "prefer-object-spread": "error",
258
- "prefer-promise-reject-errors": "error",
259
- "prefer-regex-literals": "error",
260
- "prefer-rest-params": "error",
261
- "prefer-spread": "error",
262
- "prefer-template": "error",
263
- "radix": "error",
264
- "require-atomic-updates": "error",
265
- "require-await": "error",
266
- "require-unicode-regexp": "error",
267
- "require-yield": "error",
268
- "sort-imports": "error",
269
- "sort-keys": "error",
270
- "sort-vars": "error",
271
- "strict": "error",
272
- "symbol-description": "error",
273
- "unicode-bom": "error",
274
- "use-isnan": "error",
275
- "valid-typeof": "error",
276
- "vars-on-top": "error",
277
- "yoda": "error"
278
- }
279
- });
75
+ /* eslint quote-props: off -- autogenerated so don't lint */
76
+
77
+ /*
78
+ * IMPORTANT!
79
+ *
80
+ * We cannot add a "name" property to this object because it's still used in eslintrc
81
+ * which doesn't support the "name" property. If we add a "name" property, it will
82
+ * cause an error.
83
+ */
84
+
85
+ eslintAll = Object.freeze({
86
+ "rules": {
87
+ "accessor-pairs": "error",
88
+ "array-callback-return": "error",
89
+ "arrow-body-style": "error",
90
+ "block-scoped-var": "error",
91
+ "camelcase": "error",
92
+ "capitalized-comments": "error",
93
+ "class-methods-use-this": "error",
94
+ "complexity": "error",
95
+ "consistent-return": "error",
96
+ "consistent-this": "error",
97
+ "constructor-super": "error",
98
+ "curly": "error",
99
+ "default-case": "error",
100
+ "default-case-last": "error",
101
+ "default-param-last": "error",
102
+ "dot-notation": "error",
103
+ "eqeqeq": "error",
104
+ "for-direction": "error",
105
+ "func-name-matching": "error",
106
+ "func-names": "error",
107
+ "func-style": "error",
108
+ "getter-return": "error",
109
+ "grouped-accessor-pairs": "error",
110
+ "guard-for-in": "error",
111
+ "id-denylist": "error",
112
+ "id-length": "error",
113
+ "id-match": "error",
114
+ "init-declarations": "error",
115
+ "logical-assignment-operators": "error",
116
+ "max-classes-per-file": "error",
117
+ "max-depth": "error",
118
+ "max-lines": "error",
119
+ "max-lines-per-function": "error",
120
+ "max-nested-callbacks": "error",
121
+ "max-params": "error",
122
+ "max-statements": "error",
123
+ "new-cap": "error",
124
+ "no-alert": "error",
125
+ "no-array-constructor": "error",
126
+ "no-async-promise-executor": "error",
127
+ "no-await-in-loop": "error",
128
+ "no-bitwise": "error",
129
+ "no-caller": "error",
130
+ "no-case-declarations": "error",
131
+ "no-class-assign": "error",
132
+ "no-compare-neg-zero": "error",
133
+ "no-cond-assign": "error",
134
+ "no-console": "error",
135
+ "no-const-assign": "error",
136
+ "no-constant-binary-expression": "error",
137
+ "no-constant-condition": "error",
138
+ "no-constructor-return": "error",
139
+ "no-continue": "error",
140
+ "no-control-regex": "error",
141
+ "no-debugger": "error",
142
+ "no-delete-var": "error",
143
+ "no-div-regex": "error",
144
+ "no-dupe-args": "error",
145
+ "no-dupe-class-members": "error",
146
+ "no-dupe-else-if": "error",
147
+ "no-dupe-keys": "error",
148
+ "no-duplicate-case": "error",
149
+ "no-duplicate-imports": "error",
150
+ "no-else-return": "error",
151
+ "no-empty": "error",
152
+ "no-empty-character-class": "error",
153
+ "no-empty-function": "error",
154
+ "no-empty-pattern": "error",
155
+ "no-empty-static-block": "error",
156
+ "no-eq-null": "error",
157
+ "no-eval": "error",
158
+ "no-ex-assign": "error",
159
+ "no-extend-native": "error",
160
+ "no-extra-bind": "error",
161
+ "no-extra-boolean-cast": "error",
162
+ "no-extra-label": "error",
163
+ "no-fallthrough": "error",
164
+ "no-func-assign": "error",
165
+ "no-global-assign": "error",
166
+ "no-implicit-coercion": "error",
167
+ "no-implicit-globals": "error",
168
+ "no-implied-eval": "error",
169
+ "no-import-assign": "error",
170
+ "no-inline-comments": "error",
171
+ "no-inner-declarations": "error",
172
+ "no-invalid-regexp": "error",
173
+ "no-invalid-this": "error",
174
+ "no-irregular-whitespace": "error",
175
+ "no-iterator": "error",
176
+ "no-label-var": "error",
177
+ "no-labels": "error",
178
+ "no-lone-blocks": "error",
179
+ "no-lonely-if": "error",
180
+ "no-loop-func": "error",
181
+ "no-loss-of-precision": "error",
182
+ "no-magic-numbers": "error",
183
+ "no-misleading-character-class": "error",
184
+ "no-multi-assign": "error",
185
+ "no-multi-str": "error",
186
+ "no-negated-condition": "error",
187
+ "no-nested-ternary": "error",
188
+ "no-new": "error",
189
+ "no-new-func": "error",
190
+ "no-new-native-nonconstructor": "error",
191
+ "no-new-wrappers": "error",
192
+ "no-nonoctal-decimal-escape": "error",
193
+ "no-obj-calls": "error",
194
+ "no-object-constructor": "error",
195
+ "no-octal": "error",
196
+ "no-octal-escape": "error",
197
+ "no-param-reassign": "error",
198
+ "no-plusplus": "error",
199
+ "no-promise-executor-return": "error",
200
+ "no-proto": "error",
201
+ "no-prototype-builtins": "error",
202
+ "no-redeclare": "error",
203
+ "no-regex-spaces": "error",
204
+ "no-restricted-exports": "error",
205
+ "no-restricted-globals": "error",
206
+ "no-restricted-imports": "error",
207
+ "no-restricted-properties": "error",
208
+ "no-restricted-syntax": "error",
209
+ "no-return-assign": "error",
210
+ "no-script-url": "error",
211
+ "no-self-assign": "error",
212
+ "no-self-compare": "error",
213
+ "no-sequences": "error",
214
+ "no-setter-return": "error",
215
+ "no-shadow": "error",
216
+ "no-shadow-restricted-names": "error",
217
+ "no-sparse-arrays": "error",
218
+ "no-template-curly-in-string": "error",
219
+ "no-ternary": "error",
220
+ "no-this-before-super": "error",
221
+ "no-throw-literal": "error",
222
+ "no-undef": "error",
223
+ "no-undef-init": "error",
224
+ "no-undefined": "error",
225
+ "no-underscore-dangle": "error",
226
+ "no-unexpected-multiline": "error",
227
+ "no-unmodified-loop-condition": "error",
228
+ "no-unneeded-ternary": "error",
229
+ "no-unreachable": "error",
230
+ "no-unreachable-loop": "error",
231
+ "no-unsafe-finally": "error",
232
+ "no-unsafe-negation": "error",
233
+ "no-unsafe-optional-chaining": "error",
234
+ "no-unused-expressions": "error",
235
+ "no-unused-labels": "error",
236
+ "no-unused-private-class-members": "error",
237
+ "no-unused-vars": "error",
238
+ "no-use-before-define": "error",
239
+ "no-useless-assignment": "error",
240
+ "no-useless-backreference": "error",
241
+ "no-useless-call": "error",
242
+ "no-useless-catch": "error",
243
+ "no-useless-computed-key": "error",
244
+ "no-useless-concat": "error",
245
+ "no-useless-constructor": "error",
246
+ "no-useless-escape": "error",
247
+ "no-useless-rename": "error",
248
+ "no-useless-return": "error",
249
+ "no-var": "error",
250
+ "no-void": "error",
251
+ "no-warning-comments": "error",
252
+ "no-with": "error",
253
+ "object-shorthand": "error",
254
+ "one-var": "error",
255
+ "operator-assignment": "error",
256
+ "prefer-arrow-callback": "error",
257
+ "prefer-const": "error",
258
+ "prefer-destructuring": "error",
259
+ "prefer-exponentiation-operator": "error",
260
+ "prefer-named-capture-group": "error",
261
+ "prefer-numeric-literals": "error",
262
+ "prefer-object-has-own": "error",
263
+ "prefer-object-spread": "error",
264
+ "prefer-promise-reject-errors": "error",
265
+ "prefer-regex-literals": "error",
266
+ "prefer-rest-params": "error",
267
+ "prefer-spread": "error",
268
+ "prefer-template": "error",
269
+ "radix": "error",
270
+ "require-atomic-updates": "error",
271
+ "require-await": "error",
272
+ "require-unicode-regexp": "error",
273
+ "require-yield": "error",
274
+ "sort-imports": "error",
275
+ "sort-keys": "error",
276
+ "sort-vars": "error",
277
+ "strict": "error",
278
+ "symbol-description": "error",
279
+ "unicode-bom": "error",
280
+ "use-isnan": "error",
281
+ "valid-typeof": "error",
282
+ "vars-on-top": "error",
283
+ "yoda": "error"
284
+ }
285
+ });
286
+ return eslintAll;
287
+ }
280
288
 
281
289
  /**
282
290
  * @fileoverview Configuration applied when a user configuration extends from
@@ -284,105 +292,124 @@ var eslintAll = Object.freeze({
284
292
  * @author Nicholas C. Zakas
285
293
  */
286
294
 
287
- /* eslint sort-keys: ["error", "asc"] -- Long, so make more readable */
295
+ var eslintRecommended;
296
+ var hasRequiredEslintRecommended;
288
297
 
289
- /*
290
- * IMPORTANT!
291
- *
292
- * We cannot add a "name" property to this object because it's still used in eslintrc
293
- * which doesn't support the "name" property. If we add a "name" property, it will
294
- * cause an error.
295
- */
298
+ function requireEslintRecommended () {
299
+ if (hasRequiredEslintRecommended) return eslintRecommended;
300
+ hasRequiredEslintRecommended = 1;
301
+
302
+ /* eslint sort-keys: ["error", "asc"] -- Long, so make more readable */
296
303
 
297
- var eslintRecommended = Object.freeze({
298
- rules: Object.freeze({
299
- "constructor-super": "error",
300
- "for-direction": "error",
301
- "getter-return": "error",
302
- "no-async-promise-executor": "error",
303
- "no-case-declarations": "error",
304
- "no-class-assign": "error",
305
- "no-compare-neg-zero": "error",
306
- "no-cond-assign": "error",
307
- "no-const-assign": "error",
308
- "no-constant-binary-expression": "error",
309
- "no-constant-condition": "error",
310
- "no-control-regex": "error",
311
- "no-debugger": "error",
312
- "no-delete-var": "error",
313
- "no-dupe-args": "error",
314
- "no-dupe-class-members": "error",
315
- "no-dupe-else-if": "error",
316
- "no-dupe-keys": "error",
317
- "no-duplicate-case": "error",
318
- "no-empty": "error",
319
- "no-empty-character-class": "error",
320
- "no-empty-pattern": "error",
321
- "no-empty-static-block": "error",
322
- "no-ex-assign": "error",
323
- "no-extra-boolean-cast": "error",
324
- "no-fallthrough": "error",
325
- "no-func-assign": "error",
326
- "no-global-assign": "error",
327
- "no-import-assign": "error",
328
- "no-invalid-regexp": "error",
329
- "no-irregular-whitespace": "error",
330
- "no-loss-of-precision": "error",
331
- "no-misleading-character-class": "error",
332
- "no-new-native-nonconstructor": "error",
333
- "no-nonoctal-decimal-escape": "error",
334
- "no-obj-calls": "error",
335
- "no-octal": "error",
336
- "no-prototype-builtins": "error",
337
- "no-redeclare": "error",
338
- "no-regex-spaces": "error",
339
- "no-self-assign": "error",
340
- "no-setter-return": "error",
341
- "no-shadow-restricted-names": "error",
342
- "no-sparse-arrays": "error",
343
- "no-this-before-super": "error",
344
- "no-undef": "error",
345
- "no-unexpected-multiline": "error",
346
- "no-unreachable": "error",
347
- "no-unsafe-finally": "error",
348
- "no-unsafe-negation": "error",
349
- "no-unsafe-optional-chaining": "error",
350
- "no-unused-labels": "error",
351
- "no-unused-private-class-members": "error",
352
- "no-unused-vars": "error",
353
- "no-useless-backreference": "error",
354
- "no-useless-catch": "error",
355
- "no-useless-escape": "error",
356
- "no-with": "error",
357
- "require-yield": "error",
358
- "use-isnan": "error",
359
- "valid-typeof": "error"
360
- })
361
- });
304
+ /*
305
+ * IMPORTANT!
306
+ *
307
+ * We cannot add a "name" property to this object because it's still used in eslintrc
308
+ * which doesn't support the "name" property. If we add a "name" property, it will
309
+ * cause an error.
310
+ */
311
+
312
+ eslintRecommended = Object.freeze({
313
+ rules: Object.freeze({
314
+ "constructor-super": "error",
315
+ "for-direction": "error",
316
+ "getter-return": "error",
317
+ "no-async-promise-executor": "error",
318
+ "no-case-declarations": "error",
319
+ "no-class-assign": "error",
320
+ "no-compare-neg-zero": "error",
321
+ "no-cond-assign": "error",
322
+ "no-const-assign": "error",
323
+ "no-constant-binary-expression": "error",
324
+ "no-constant-condition": "error",
325
+ "no-control-regex": "error",
326
+ "no-debugger": "error",
327
+ "no-delete-var": "error",
328
+ "no-dupe-args": "error",
329
+ "no-dupe-class-members": "error",
330
+ "no-dupe-else-if": "error",
331
+ "no-dupe-keys": "error",
332
+ "no-duplicate-case": "error",
333
+ "no-empty": "error",
334
+ "no-empty-character-class": "error",
335
+ "no-empty-pattern": "error",
336
+ "no-empty-static-block": "error",
337
+ "no-ex-assign": "error",
338
+ "no-extra-boolean-cast": "error",
339
+ "no-fallthrough": "error",
340
+ "no-func-assign": "error",
341
+ "no-global-assign": "error",
342
+ "no-import-assign": "error",
343
+ "no-invalid-regexp": "error",
344
+ "no-irregular-whitespace": "error",
345
+ "no-loss-of-precision": "error",
346
+ "no-misleading-character-class": "error",
347
+ "no-new-native-nonconstructor": "error",
348
+ "no-nonoctal-decimal-escape": "error",
349
+ "no-obj-calls": "error",
350
+ "no-octal": "error",
351
+ "no-prototype-builtins": "error",
352
+ "no-redeclare": "error",
353
+ "no-regex-spaces": "error",
354
+ "no-self-assign": "error",
355
+ "no-setter-return": "error",
356
+ "no-shadow-restricted-names": "error",
357
+ "no-sparse-arrays": "error",
358
+ "no-this-before-super": "error",
359
+ "no-undef": "error",
360
+ "no-unexpected-multiline": "error",
361
+ "no-unreachable": "error",
362
+ "no-unsafe-finally": "error",
363
+ "no-unsafe-negation": "error",
364
+ "no-unsafe-optional-chaining": "error",
365
+ "no-unused-labels": "error",
366
+ "no-unused-private-class-members": "error",
367
+ "no-unused-vars": "error",
368
+ "no-useless-backreference": "error",
369
+ "no-useless-catch": "error",
370
+ "no-useless-escape": "error",
371
+ "no-with": "error",
372
+ "require-yield": "error",
373
+ "use-isnan": "error",
374
+ "valid-typeof": "error"
375
+ })
376
+ });
377
+ return eslintRecommended;
378
+ }
362
379
 
363
380
  /**
364
381
  * @fileoverview Main package entrypoint.
365
382
  * @author Nicholas C. Zakas
366
383
  */
367
384
 
368
- const { version } = require$$0;
385
+ var src;
386
+ var hasRequiredSrc;
369
387
 
370
- //------------------------------------------------------------------------------
371
- // Public Interface
372
- //------------------------------------------------------------------------------
388
+ function requireSrc () {
389
+ if (hasRequiredSrc) return src;
390
+ hasRequiredSrc = 1;
373
391
 
374
- var src = {
375
- meta: {
376
- name: "@eslint/js",
377
- version
378
- },
379
- configs: {
380
- all: eslintAll,
381
- recommended: eslintRecommended
382
- }
383
- };
392
+ const { version } = require$$0;
393
+
394
+ //------------------------------------------------------------------------------
395
+ // Public Interface
396
+ //------------------------------------------------------------------------------
384
397
 
385
- var js = /*@__PURE__*/getDefaultExportFromCjs(src);
398
+ src = {
399
+ meta: {
400
+ name: "@eslint/js",
401
+ version
402
+ },
403
+ configs: {
404
+ all: requireEslintAll(),
405
+ recommended: requireEslintRecommended()
406
+ }
407
+ };
408
+ return src;
409
+ }
410
+
411
+ var srcExports = requireSrc();
412
+ var js = /*@__PURE__*/getDefaultExportFromCjs(srcExports);
386
413
 
387
414
  const typescript = [
388
415
  ...plugins["typescript-eslint"].configs.recommended,
@@ -477,19 +504,6 @@ const vue = (options) => {
477
504
  return config;
478
505
  };
479
506
 
480
- const pluginImportTypescript = Object.keys(pluginImport.flatConfigs.typescript).reduce(
481
- (acc, key) => ({
482
- ...acc,
483
- [key]: Object.keys(pluginImport.flatConfigs.typescript[key]).reduce(
484
- (innerAcc, curr) => ({
485
- ...innerAcc,
486
- [curr.replace("import-x", "import")]: pluginImport.flatConfigs.typescript[key][curr]
487
- }),
488
- {}
489
- )
490
- }),
491
- {}
492
- );
493
507
  const config = (options) => {
494
508
  const opts = {
495
509
  noJsx: true,
@@ -537,32 +551,15 @@ const config = (options) => {
537
551
  ],
538
552
  // Console and debugger settings depending whether we're on production or not
539
553
  "no-console": process.env.NODE_ENV === "production" ? "warn" : "off",
540
- "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off"
541
- }
542
- },
543
- // Import
544
- {
545
- name: "kouts/import",
546
- plugins: {
547
- import: pluginImport
548
- },
549
- ...opts.ts ? pluginImportTypescript : {},
550
- rules: {
551
- // TypeScript compilation already ensures that named imports exist in the referenced module
552
- // and has its own version of no-unused-vars
554
+ "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off",
555
+ // Import rules
553
556
  ...opts.ts ? {
554
- "import/named": "off",
557
+ "import-x/named": "off",
555
558
  "no-unused-vars": "off"
556
559
  } : {},
557
- "import/export": "error",
558
- "import/first": "error",
559
- "import/no-duplicates": "error",
560
- "import/no-mutable-exports": "error",
561
- "import/no-named-default": "error",
562
- "import/no-self-import": "error",
563
- "import/no-webpack-loader-syntax": "error",
564
- "import/no-absolute-path": ["error", { esmodule: true, commonjs: true, amd: false }],
565
- "import/newline-after-import": ["error", { count: 1 }]
560
+ "import-x/no-mutable-exports": "error",
561
+ "import-x/newline-after-import": ["error", { count: 1 }],
562
+ "import-x/no-self-import": "error"
566
563
  }
567
564
  },
568
565
  // Sort imports