@azat-io/eslint-config 2.0.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.
@@ -0,0 +1,631 @@
1
+ import eslintCommentsPlugin from "@eslint-community/eslint-plugin-eslint-comments";
2
+ import preferArrowPlugin from "eslint-plugin-prefer-arrow";
3
+ import preferLetPlugin from "eslint-plugin-prefer-let";
4
+ import importXPlugin from "eslint-plugin-import-x";
5
+ import promisePlugin from "eslint-plugin-promise";
6
+ import sonarjsPlugin from "eslint-plugin-sonarjs";
7
+ import unicornPlugin from "eslint-plugin-unicorn";
8
+ import regexpPlugin from "eslint-plugin-regexp";
9
+ import jsdocPlugin from "eslint-plugin-jsdoc";
10
+ import globals from "globals";
11
+ let core = (config) => {
12
+ let files = ["**/*.js", "**/*.cjs", "**/*.mjs"];
13
+ if (config.typescript) {
14
+ files.push("**/*.ts", "**/*.cts", "**/*.mts");
15
+ }
16
+ if (config.react || config.qwik) {
17
+ files.push("**/*.jsx");
18
+ if (config.typescript) {
19
+ files.push("**/*.tsx");
20
+ }
21
+ }
22
+ if (config.astro) {
23
+ files.push("**/*.astro");
24
+ }
25
+ if (config.svelte) {
26
+ files.push("**/*.svelte");
27
+ }
28
+ if (config.vue) {
29
+ files.push("**/*.vue");
30
+ }
31
+ return {
32
+ files,
33
+ languageOptions: {
34
+ globals: {
35
+ ...globals.browser,
36
+ ...globals.es2025,
37
+ ...globals.node
38
+ },
39
+ parserOptions: {
40
+ ecmaVersion: "latest",
41
+ sourceType: "module"
42
+ }
43
+ },
44
+ plugins: {
45
+ "@eslint-community/eslint-comments": eslintCommentsPlugin,
46
+ "import-x": importXPlugin,
47
+ jsdoc: jsdocPlugin,
48
+ "prefer-arrow": preferArrowPlugin,
49
+ "prefer-let": preferLetPlugin,
50
+ promise: promisePlugin,
51
+ regexp: regexpPlugin,
52
+ sonarjs: sonarjsPlugin,
53
+ unicorn: unicornPlugin
54
+ },
55
+ rules: {
56
+ "array-callback-return": [
57
+ "error",
58
+ {
59
+ allowImplicit: false,
60
+ checkForEach: false
61
+ }
62
+ ],
63
+ "arrow-body-style": ["error", "as-needed"],
64
+ camelcase: [
65
+ "error",
66
+ {
67
+ ignoreGlobals: true,
68
+ properties: "always"
69
+ }
70
+ ],
71
+ "capitalized-comments": [
72
+ "error",
73
+ "always",
74
+ {
75
+ ignorePattern: "c8|v8|spell-checker"
76
+ }
77
+ ],
78
+ "consistent-return": "error",
79
+ "constructor-super": "error",
80
+ curly: ["error", "all"],
81
+ "default-case-last": "error",
82
+ "default-param-last": "error",
83
+ "dot-notation": "error",
84
+ eqeqeq: "error",
85
+ "func-names": ["error", "never"],
86
+ "id-length": [
87
+ "error",
88
+ {
89
+ exceptions: ["_", "a", "b", "i", "j", "t", "x", "y", "z"],
90
+ min: 2,
91
+ properties: "never"
92
+ }
93
+ ],
94
+ "logical-assignment-operators": ["error", "always"],
95
+ "max-params": [
96
+ "error",
97
+ {
98
+ max: 3
99
+ }
100
+ ],
101
+ "new-cap": [
102
+ "error",
103
+ {
104
+ capIsNew: false,
105
+ newIsCap: true,
106
+ properties: true
107
+ }
108
+ ],
109
+ "no-array-constructor": "error",
110
+ "no-async-promise-executor": "error",
111
+ "no-await-in-loop": "error",
112
+ "no-caller": "error",
113
+ "no-case-declarations": "error",
114
+ "no-class-assign": "error",
115
+ "no-compare-neg-zero": "error",
116
+ "no-cond-assign": "error",
117
+ "no-console": [
118
+ "error",
119
+ {
120
+ allow: ["error", "warn", "info"]
121
+ }
122
+ ],
123
+ "no-const-assign": "error",
124
+ "no-constant-binary-expression": "error",
125
+ "no-constant-condition": "error",
126
+ "no-constructor-return": "error",
127
+ "no-control-regex": "error",
128
+ "no-debugger": "error",
129
+ "no-delete-var": "error",
130
+ "no-dupe-args": "error",
131
+ "no-dupe-class-members": "error",
132
+ "no-dupe-else-if": "error",
133
+ "no-dupe-keys": "error",
134
+ "no-duplicate-case": "error",
135
+ "no-else-return": "error",
136
+ "no-empty": [
137
+ "error",
138
+ {
139
+ allowEmptyCatch: true
140
+ }
141
+ ],
142
+ "no-empty-character-class": "error",
143
+ "no-empty-pattern": "error",
144
+ "no-empty-static-block": "error",
145
+ "no-eval": "error",
146
+ "no-ex-assign": "error",
147
+ "no-extend-native": "error",
148
+ "no-extra-bind": "error",
149
+ "no-extra-boolean-cast": "error",
150
+ "no-extra-label": "error",
151
+ "no-fallthrough": "error",
152
+ "no-func-assign": "error",
153
+ "no-global-assign": "error",
154
+ "no-implied-eval": "error",
155
+ "no-import-assign": "error",
156
+ "no-invalid-regexp": "error",
157
+ "no-irregular-whitespace": [
158
+ "error",
159
+ {
160
+ skipComments: true,
161
+ skipJSXText: true,
162
+ skipRegExps: true,
163
+ skipStrings: true,
164
+ skipTemplates: true
165
+ }
166
+ ],
167
+ "no-iterator": "error",
168
+ "no-label-var": "error",
169
+ "no-labels": [
170
+ "error",
171
+ {
172
+ allowLoop: false,
173
+ allowSwitch: false
174
+ }
175
+ ],
176
+ "no-loop-func": "error",
177
+ "no-loss-of-precision": "error",
178
+ "no-multi-assign": "error",
179
+ "no-multi-str": "error",
180
+ "no-nested-ternary": "error",
181
+ "no-new": "error",
182
+ "no-new-func": "error",
183
+ "no-new-native-nonconstructor": "error",
184
+ "no-new-wrappers": "error",
185
+ "no-nonoctal-decimal-escape": "error",
186
+ "no-obj-calls": "error",
187
+ "no-object-constructor": "error",
188
+ "no-octal": "error",
189
+ "no-octal-escape": "error",
190
+ "no-param-reassign": "error",
191
+ "no-promise-executor-return": "error",
192
+ "no-proto": "error",
193
+ "no-prototype-builtins": "error",
194
+ "no-regex-spaces": "error",
195
+ "no-return-assign": ["error", "except-parens"],
196
+ "no-self-assign": [
197
+ "error",
198
+ {
199
+ props: true
200
+ }
201
+ ],
202
+ "no-self-compare": "error",
203
+ "no-setter-return": "error",
204
+ "no-shadow": "error",
205
+ "no-shadow-restricted-names": "error",
206
+ "no-sparse-arrays": "error",
207
+ "no-template-curly-in-string": "error",
208
+ "no-this-before-super": "error",
209
+ "no-undef": "error",
210
+ "no-undef-init": "error",
211
+ "no-undefined": "error",
212
+ "no-unexpected-multiline": "error",
213
+ "no-unneeded-ternary": [
214
+ "error",
215
+ {
216
+ defaultAssignment: false
217
+ }
218
+ ],
219
+ "no-unreachable": "error",
220
+ "no-unreachable-loop": "error",
221
+ "no-unsafe-finally": "error",
222
+ "no-unsafe-negation": "error",
223
+ "no-unsafe-optional-chaining": "error",
224
+ "no-unused-expressions": [
225
+ "error",
226
+ {
227
+ allowShortCircuit: true,
228
+ allowTaggedTemplates: true,
229
+ allowTernary: true
230
+ }
231
+ ],
232
+ "no-unused-private-class-members": "error",
233
+ "no-unused-vars": [
234
+ "error",
235
+ {
236
+ argsIgnorePattern: "^_",
237
+ caughtErrorsIgnorePattern: "^_",
238
+ ignoreRestSiblings: true,
239
+ varsIgnorePattern: "^_"
240
+ }
241
+ ],
242
+ "no-use-before-define": [
243
+ "error",
244
+ {
245
+ classes: false,
246
+ functions: false,
247
+ variables: false
248
+ }
249
+ ],
250
+ "no-useless-assignment": config.astro || config.react || config.qwik ? "off" : "error",
251
+ "no-useless-backreference": "error",
252
+ "no-useless-call": "error",
253
+ "no-useless-catch": "error",
254
+ "no-useless-computed-key": "error",
255
+ "no-useless-concat": "error",
256
+ "no-useless-constructor": "error",
257
+ "no-useless-escape": "error",
258
+ "no-useless-rename": "error",
259
+ "no-useless-return": "error",
260
+ "no-var": "error",
261
+ "no-void": "error",
262
+ "no-with": "error",
263
+ "object-shorthand": ["error", "always"],
264
+ "one-var": [
265
+ "error",
266
+ {
267
+ initialized: "never"
268
+ }
269
+ ],
270
+ "operator-assignment": ["error", "always"],
271
+ "prefer-arrow-callback": "error",
272
+ "prefer-destructuring": "error",
273
+ "prefer-exponentiation-operator": "error",
274
+ "prefer-named-capture-group": "error",
275
+ "prefer-numeric-literals": "error",
276
+ "prefer-object-has-own": "error",
277
+ "prefer-object-spread": "error",
278
+ "prefer-promise-reject-errors": "error",
279
+ "prefer-regex-literals": [
280
+ "error",
281
+ {
282
+ disallowRedundantWrapping: true
283
+ }
284
+ ],
285
+ "prefer-rest-params": "error",
286
+ "prefer-spread": "error",
287
+ "prefer-template": "error",
288
+ "require-await": "error",
289
+ "require-yield": "error",
290
+ strict: ["error", "never"],
291
+ "symbol-description": "error",
292
+ "use-isnan": [
293
+ "error",
294
+ {
295
+ enforceForIndexOf: true,
296
+ enforceForSwitchCase: true
297
+ }
298
+ ],
299
+ "valid-typeof": [
300
+ "error",
301
+ {
302
+ requireStringLiterals: true
303
+ }
304
+ ],
305
+ yoda: ["error", "never"],
306
+ "@eslint-community/eslint-comments/disable-enable-pair": "error",
307
+ "@eslint-community/eslint-comments/no-aggregating-enable": "error",
308
+ "@eslint-community/eslint-comments/no-duplicate-disable": "error",
309
+ "@eslint-community/eslint-comments/no-unlimited-disable": "error",
310
+ "@eslint-community/eslint-comments/no-unused-disable": "error",
311
+ "@eslint-community/eslint-comments/no-unused-enable": "error",
312
+ "import-x/consistent-type-specifier-style": ["error", "prefer-top-level"],
313
+ "import-x/default": "error",
314
+ "import-x/export": "error",
315
+ "import-x/first": "error",
316
+ "import-x/named": "error",
317
+ "import-x/namespace": "error",
318
+ "import-x/newline-after-import": "error",
319
+ "import-x/no-absolute-path": "error",
320
+ "import-x/no-amd": "error",
321
+ "import-x/no-empty-named-blocks": "error",
322
+ "import-x/no-extraneous-dependencies": [
323
+ "error",
324
+ {
325
+ devDependencies: true,
326
+ optionalDependencies: false,
327
+ peerDependencies: false
328
+ }
329
+ ],
330
+ "import-x/no-import-module-exports": "error",
331
+ "import-x/no-named-as-default-member": "error",
332
+ "import-x/no-named-default": "error",
333
+ "import-x/no-self-import": "error",
334
+ "import-x/no-unresolved": [
335
+ "error",
336
+ config.astro ? {
337
+ ignore: ["^astro:(assets|content|transitions)"]
338
+ } : {}
339
+ ],
340
+ "import-x/no-useless-path-segments": "error",
341
+ "import-x/no-webpack-loader-syntax": "error",
342
+ "jsdoc/check-access": "error",
343
+ "jsdoc/check-alignment": "error",
344
+ "jsdoc/check-indentation": "error",
345
+ "jsdoc/check-line-alignment": "error",
346
+ "jsdoc/check-param-names": "error",
347
+ "jsdoc/check-property-names": "error",
348
+ "jsdoc/check-syntax": "error",
349
+ "jsdoc/check-tag-names": "error",
350
+ "jsdoc/check-template-names": "error",
351
+ "jsdoc/check-types": "error",
352
+ "jsdoc/check-values": "error",
353
+ "jsdoc/empty-tags": "error",
354
+ "jsdoc/implements-on-classes": "error",
355
+ "jsdoc/imports-as-dependencies": "error",
356
+ "jsdoc/informative-docs": "error",
357
+ "jsdoc/multiline-blocks": "error",
358
+ "jsdoc/no-bad-blocks": "error",
359
+ "jsdoc/no-blank-block-descriptions": "error",
360
+ "jsdoc/no-blank-blocks": "error",
361
+ "jsdoc/no-defaults": "error",
362
+ "jsdoc/no-multi-asterisks": "error",
363
+ "jsdoc/no-undefined-types": "error",
364
+ "jsdoc/require-asterisk-prefix": "error",
365
+ "jsdoc/require-description": "error",
366
+ "jsdoc/require-hyphen-before-param-description": "error",
367
+ "jsdoc/require-param": "error",
368
+ "jsdoc/require-param-description": "error",
369
+ "jsdoc/require-param-name": "error",
370
+ "jsdoc/require-param-type": "error",
371
+ "jsdoc/require-property": "error",
372
+ "jsdoc/require-property-description": "error",
373
+ "jsdoc/require-property-name": "error",
374
+ "jsdoc/require-property-type": "error",
375
+ "jsdoc/require-returns": "error",
376
+ "jsdoc/require-returns-check": "error",
377
+ "jsdoc/require-returns-description": "error",
378
+ "jsdoc/require-returns-type": "error",
379
+ "jsdoc/require-yields-check": "error",
380
+ "jsdoc/sort-tags": "error",
381
+ "jsdoc/tag-lines": "error",
382
+ "jsdoc/valid-types": "error",
383
+ "prefer-arrow/prefer-arrow-functions": [
384
+ "error",
385
+ {
386
+ classPropertiesAllowed: false,
387
+ disallowPrototype: true,
388
+ singleReturnOnly: false
389
+ }
390
+ ],
391
+ "prefer-let/prefer-let": "error",
392
+ "promise/catch-or-return": "error",
393
+ "promise/no-callback-in-promise": "error",
394
+ "promise/no-multiple-resolved": "error",
395
+ "promise/no-nesting": "error",
396
+ "promise/no-new-statics": "error",
397
+ "promise/no-promise-in-callback": "error",
398
+ "promise/no-return-in-finally": "error",
399
+ "promise/no-return-wrap": "error",
400
+ "promise/param-names": "error",
401
+ "promise/spec-only": "error",
402
+ "promise/valid-params": "error",
403
+ "regexp/confusing-quantifier": "error",
404
+ "regexp/control-character-escape": "error",
405
+ "regexp/letter-case": [
406
+ "error",
407
+ {
408
+ caseInsensitive: "lowercase",
409
+ controlEscape: "lowercase",
410
+ hexadecimalEscape: "lowercase",
411
+ unicodeEscape: "lowercase"
412
+ }
413
+ ],
414
+ "regexp/match-any": "error",
415
+ "regexp/negation": "error",
416
+ "regexp/no-contradiction-with-assertion": "error",
417
+ "regexp/no-control-character": "error",
418
+ "regexp/no-dupe-characters-character-class": "error",
419
+ "regexp/no-dupe-disjunctions": "error",
420
+ "regexp/no-empty-alternative": "error",
421
+ "regexp/no-empty-capturing-group": "error",
422
+ "regexp/no-empty-character-class": "error",
423
+ "regexp/no-empty-group": "error",
424
+ "regexp/no-empty-lookarounds-assertion": "error",
425
+ "regexp/no-empty-string-literal": "error",
426
+ "regexp/no-escape-backspace": "error",
427
+ "regexp/no-invalid-regexp": "error",
428
+ "regexp/no-invisible-character": "error",
429
+ "regexp/no-lazy-ends": "error",
430
+ "regexp/no-legacy-features": "error",
431
+ "regexp/no-misleading-capturing-group": "error",
432
+ "regexp/no-missing-g-flag": "error",
433
+ "regexp/no-non-standard-flag": "error",
434
+ "regexp/no-obscure-range": "error",
435
+ "regexp/no-octal": "error",
436
+ "regexp/no-optional-assertion": "error",
437
+ "regexp/no-potentially-useless-backreference": "error",
438
+ "regexp/no-standalone-backslash": "error",
439
+ "regexp/no-super-linear-backtracking": "error",
440
+ "regexp/no-trivially-nested-assertion": "error",
441
+ "regexp/no-trivially-nested-quantifier": "error",
442
+ "regexp/no-unused-capturing-group": "error",
443
+ "regexp/no-useless-assertions": "error",
444
+ "regexp/no-useless-backreference": "error",
445
+ "regexp/no-useless-character-class": "error",
446
+ "regexp/no-useless-dollar-replacements": "error",
447
+ "regexp/no-useless-escape": "error",
448
+ "regexp/no-useless-flag": "error",
449
+ "regexp/no-useless-lazy": "error",
450
+ "regexp/no-useless-non-capturing-group": "error",
451
+ "regexp/no-useless-quantifier": "error",
452
+ "regexp/no-useless-range": "error",
453
+ "regexp/no-useless-set-operand": "error",
454
+ "regexp/no-useless-string-literal": "error",
455
+ "regexp/no-useless-two-nums-quantifier": "error",
456
+ "regexp/no-zero-quantifier": "error",
457
+ "regexp/optimal-lookaround-quantifier": "error",
458
+ "regexp/optimal-quantifier-concatenation": "error",
459
+ "regexp/prefer-character-class": "error",
460
+ "regexp/prefer-d": "error",
461
+ "regexp/prefer-escape-replacement-dollar-char": "error",
462
+ "regexp/prefer-lookaround": "error",
463
+ "regexp/prefer-named-backreference": "error",
464
+ "regexp/prefer-named-capture-group": "error",
465
+ "regexp/prefer-named-replacement": "error",
466
+ "regexp/prefer-plus-quantifier": "error",
467
+ "regexp/prefer-predefined-assertion": "error",
468
+ "regexp/prefer-quantifier": "error",
469
+ "regexp/prefer-question-quantifier": "error",
470
+ "regexp/prefer-range": "error",
471
+ "regexp/prefer-set-operation": "error",
472
+ "regexp/prefer-star-quantifier": "error",
473
+ "regexp/prefer-unicode-codepoint-escapes": "error",
474
+ "regexp/prefer-w": "error",
475
+ "regexp/require-unicode-regexp": "error",
476
+ "regexp/simplify-set-operations": "error",
477
+ "regexp/sort-alternatives": "error",
478
+ "regexp/sort-character-class-elements": "error",
479
+ "regexp/sort-flags": "error",
480
+ "regexp/strict": "error",
481
+ "regexp/unicode-escape": "error",
482
+ "regexp/unicode-property": "error",
483
+ "regexp/use-ignore-case": "error",
484
+ "sonarjs/accessor-pairs": "error",
485
+ "sonarjs/arguments-order": "error",
486
+ "sonarjs/array-callback-without-return": "error",
487
+ "sonarjs/for-in": "error",
488
+ "sonarjs/no-collapsible-if": "error",
489
+ "sonarjs/no-duplicated-branches": "error",
490
+ "sonarjs/no-equals-in-for-termination": "error",
491
+ "sonarjs/no-gratuitous-expressions": "error",
492
+ "sonarjs/no-identical-conditions": "error",
493
+ "sonarjs/no-identical-expressions": "error",
494
+ "sonarjs/no-identical-functions": "error",
495
+ "sonarjs/no-ignored-exceptions": "error",
496
+ "sonarjs/no-ignored-return": "error",
497
+ "sonarjs/no-infinite-loop": "error",
498
+ "sonarjs/no-inverted-boolean-check": "error",
499
+ "sonarjs/no-misleading-array-reverse": "error",
500
+ "sonarjs/no-redundant-boolean": "error",
501
+ "sonarjs/no-same-line-conditional": "error",
502
+ "sonarjs/no-small-switch": "error",
503
+ "sonarjs/no-undefined-argument": "error",
504
+ "sonarjs/prefer-immediate-return": "error",
505
+ "sonarjs/prefer-promise-shorthand": "error",
506
+ "sonarjs/prefer-single-boolean-return": "error",
507
+ "sonarjs/reduce-initial-value": "error",
508
+ "sonarjs/sonar-prefer-optional-chain": "error",
509
+ "unicorn/better-regex": "error",
510
+ "unicorn/catch-error-name": "error",
511
+ "unicorn/consistent-destructuring": "error",
512
+ "unicorn/consistent-empty-array-spread": "error",
513
+ "unicorn/consistent-existence-index-check": "error",
514
+ "unicorn/custom-error-definition": "error",
515
+ "unicorn/error-message": "error",
516
+ "unicorn/escape-case": "error",
517
+ "unicorn/new-for-builtins": "error",
518
+ "unicorn/no-array-for-each": "error",
519
+ "unicorn/no-array-method-this-argument": "error",
520
+ "unicorn/no-array-push-push": "error",
521
+ "unicorn/no-await-in-promise-methods": "error",
522
+ "unicorn/no-for-loop": "error",
523
+ "unicorn/no-hex-escape": "error",
524
+ "unicorn/no-instanceof-array": "error",
525
+ "unicorn/no-invalid-fetch-options": "error",
526
+ "unicorn/no-invalid-remove-event-listener": "error",
527
+ "unicorn/no-length-as-slice-end": "error",
528
+ "unicorn/no-negated-condition": "error",
529
+ "unicorn/no-negation-in-equality-check": "error",
530
+ "unicorn/no-new-array": "error",
531
+ "unicorn/no-new-buffer": "error",
532
+ "unicorn/no-process-exit": "error",
533
+ "unicorn/no-single-promise-in-promise-methods": "error",
534
+ "unicorn/no-static-only-class": "error",
535
+ "unicorn/no-this-assignment": "error",
536
+ "unicorn/no-typeof-undefined": "error",
537
+ "unicorn/no-unnecessary-await": "error",
538
+ "unicorn/no-unreadable-array-destructuring": "error",
539
+ "unicorn/no-unreadable-iife": "error",
540
+ "unicorn/no-unused-properties": "error",
541
+ "unicorn/no-useless-fallback-in-spread": "error",
542
+ "unicorn/no-useless-length-check": "error",
543
+ "unicorn/no-useless-promise-resolve-reject": "error",
544
+ "unicorn/no-useless-spread": "error",
545
+ "unicorn/no-useless-switch-case": "error",
546
+ "unicorn/no-useless-undefined": [
547
+ "error",
548
+ {
549
+ checkArguments: false
550
+ }
551
+ ],
552
+ "unicorn/no-zero-fractions": ["error"],
553
+ "unicorn/numeric-separators-style": [
554
+ "error",
555
+ {
556
+ onlyIfContainsSeparator: true
557
+ }
558
+ ],
559
+ "unicorn/prefer-add-event-listener": "error",
560
+ "unicorn/prefer-array-find": "error",
561
+ "unicorn/prefer-array-flat": "error",
562
+ "unicorn/prefer-array-flat-map": "error",
563
+ "unicorn/prefer-array-index-of": "error",
564
+ "unicorn/prefer-array-some": "error",
565
+ "unicorn/prefer-at": "error",
566
+ "unicorn/prefer-blob-reading-methods": "error",
567
+ "unicorn/prefer-date-now": "error",
568
+ "unicorn/prefer-default-parameters": "error",
569
+ "unicorn/prefer-dom-node-append": "error",
570
+ "unicorn/prefer-dom-node-dataset": "error",
571
+ "unicorn/prefer-dom-node-remove": "error",
572
+ "unicorn/prefer-dom-node-text-content": "error",
573
+ "unicorn/prefer-event-target": "error",
574
+ "unicorn/prefer-export-from": "error",
575
+ "unicorn/prefer-global-this": "error",
576
+ "unicorn/prefer-includes": "error",
577
+ "unicorn/prefer-keyboard-event-key": "error",
578
+ "unicorn/prefer-logical-operator-over-ternary": "error",
579
+ "unicorn/prefer-math-min-max": "error",
580
+ "unicorn/prefer-modern-dom-apis": "error",
581
+ "unicorn/prefer-modern-math-apis": "error",
582
+ "unicorn/prefer-native-coercion-functions": "error",
583
+ "unicorn/prefer-negative-index": "error",
584
+ "unicorn/prefer-number-properties": "error",
585
+ "unicorn/prefer-object-from-entries": "error",
586
+ "unicorn/prefer-query-selector": "error",
587
+ "unicorn/prefer-regexp-test": "error",
588
+ "unicorn/prefer-set-has": "error",
589
+ "unicorn/prefer-set-size": "error",
590
+ "unicorn/prefer-spread": "error",
591
+ "unicorn/prefer-string-replace-all": "error",
592
+ "unicorn/prefer-string-slice": "error",
593
+ "unicorn/prefer-string-starts-ends-with": "error",
594
+ "unicorn/prefer-string-trim-start-end": "error",
595
+ "unicorn/prefer-structured-clone": "error",
596
+ "unicorn/prefer-top-level-await": "error",
597
+ "unicorn/prefer-type-error": "error",
598
+ "unicorn/prevent-abbreviations": [
599
+ "error",
600
+ {
601
+ allowList: {
602
+ attrs: true,
603
+ env: config.astro,
604
+ i: true,
605
+ Props: true,
606
+ props: true,
607
+ rel: ["astro", "react", "svelte", "vue"].some(
608
+ (configName) => config[configName]
609
+ )
610
+ }
611
+ }
612
+ ],
613
+ "unicorn/require-array-join-separator": "error",
614
+ "unicorn/require-number-to-fixed-digits-argument": "error",
615
+ "unicorn/text-encoding-identifier-case": "error",
616
+ "unicorn/throw-new-error": "error"
617
+ },
618
+ settings: {
619
+ "import-x/resolver": {
620
+ node: true,
621
+ typescript: config.typescript
622
+ },
623
+ jsdoc: {
624
+ mode: "jsdoc"
625
+ }
626
+ }
627
+ };
628
+ };
629
+ export {
630
+ core
631
+ };