@ntnyq/eslint-config 6.0.0-beta.13 → 6.0.0-beta.15
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/dist/index.d.mts +326 -161
- package/dist/index.mjs +3 -0
- package/package.json +29 -29
package/dist/index.d.mts
CHANGED
|
@@ -468,7 +468,7 @@ type ConfigCommandOptions = ESLintPluginCommandOptions;
|
|
|
468
468
|
* @param options - {@link ConfigCommandOptions}
|
|
469
469
|
* @returns ESLint configs
|
|
470
470
|
*/
|
|
471
|
-
declare const configCommand: (options?:
|
|
471
|
+
declare const configCommand: (options?: ConfigCommandOptions) => TypedConfigItem[];
|
|
472
472
|
//#endregion
|
|
473
473
|
//#region src/configs/ignores.d.ts
|
|
474
474
|
/**
|
|
@@ -514,7 +514,7 @@ declare const configImportX: (options?: ConfigImportXOptions) => TypedConfigItem
|
|
|
514
514
|
/**
|
|
515
515
|
* Built-in presets of `eslint-plugin-unicorn`
|
|
516
516
|
*/
|
|
517
|
-
declare const PLUGIN_UNICORN_PRESET: readonly [
|
|
517
|
+
declare const PLUGIN_UNICORN_PRESET: readonly ['all', 'recommended', 'unopinionated'];
|
|
518
518
|
/**
|
|
519
519
|
* Options type of {@link configUnicorn}
|
|
520
520
|
*/
|
|
@@ -1157,6 +1157,11 @@ interface RuleOptions {
|
|
|
1157
1157
|
* @see https://html-eslint.org/docs/rules/require-closing-tags
|
|
1158
1158
|
*/
|
|
1159
1159
|
'@html-eslint/require-closing-tags'?: Linter.RuleEntry<HtmlEslintRequireClosingTags>;
|
|
1160
|
+
/**
|
|
1161
|
+
* Require `<details>` elements to have a `<summary>` as their first child element.
|
|
1162
|
+
* @see https://html-eslint.org/docs/rules/require-details-summary
|
|
1163
|
+
*/
|
|
1164
|
+
'@html-eslint/require-details-summary'?: Linter.RuleEntry<[]>;
|
|
1160
1165
|
/**
|
|
1161
1166
|
* Require `<!DOCTYPE HTML>` in HTML
|
|
1162
1167
|
* @see https://html-eslint.org/docs/rules/require-doctype
|
|
@@ -3677,6 +3682,11 @@ interface RuleOptions {
|
|
|
3677
3682
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/fenced-code-language.md
|
|
3678
3683
|
*/
|
|
3679
3684
|
'markdown/fenced-code-language'?: Linter.RuleEntry<MarkdownFencedCodeLanguage>;
|
|
3685
|
+
/**
|
|
3686
|
+
* Require or disallow metadata for fenced code blocks
|
|
3687
|
+
* @see https://github.com/eslint/markdown/blob/main/docs/rules/fenced-code-meta.md
|
|
3688
|
+
*/
|
|
3689
|
+
'markdown/fenced-code-meta'?: Linter.RuleEntry<MarkdownFencedCodeMeta>;
|
|
3680
3690
|
/**
|
|
3681
3691
|
* Enforce heading levels increment by one
|
|
3682
3692
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/heading-increment.md
|
|
@@ -5839,6 +5849,11 @@ interface RuleOptions {
|
|
|
5839
5849
|
* @see https://sveltejs.github.io/eslint-plugin-svelte/rules/max-attributes-per-line/
|
|
5840
5850
|
*/
|
|
5841
5851
|
'svelte/max-attributes-per-line'?: Linter.RuleEntry<SvelteMaxAttributesPerLine>;
|
|
5852
|
+
/**
|
|
5853
|
+
* enforce maximum number of lines in svelte component blocks
|
|
5854
|
+
* @see https://sveltejs.github.io/eslint-plugin-svelte/rules/max-lines-per-block/
|
|
5855
|
+
*/
|
|
5856
|
+
'svelte/max-lines-per-block'?: Linter.RuleEntry<SvelteMaxLinesPerBlock>;
|
|
5842
5857
|
/**
|
|
5843
5858
|
* enforce unified spacing in mustache
|
|
5844
5859
|
* @see https://sveltejs.github.io/eslint-plugin-svelte/rules/mustache-spacing/
|
|
@@ -5938,7 +5953,7 @@ interface RuleOptions {
|
|
|
5938
5953
|
*/
|
|
5939
5954
|
'svelte/no-navigation-without-base'?: Linter.RuleEntry<SvelteNoNavigationWithoutBase>;
|
|
5940
5955
|
/**
|
|
5941
|
-
* disallow
|
|
5956
|
+
* disallow internal navigation (links, `goto()`, `pushState()`, `replaceState()`) without a `resolve()`
|
|
5942
5957
|
* @see https://sveltejs.github.io/eslint-plugin-svelte/rules/no-navigation-without-resolve/
|
|
5943
5958
|
*/
|
|
5944
5959
|
'svelte/no-navigation-without-resolve'?: Linter.RuleEntry<SvelteNoNavigationWithoutResolve>;
|
|
@@ -6313,730 +6328,750 @@ interface RuleOptions {
|
|
|
6313
6328
|
'unicode-bom'?: Linter.RuleEntry<UnicodeBom>;
|
|
6314
6329
|
/**
|
|
6315
6330
|
* Improve regexes by making them shorter, consistent, and safer.
|
|
6316
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6331
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/better-regex.md
|
|
6317
6332
|
*/
|
|
6318
6333
|
'unicorn/better-regex'?: Linter.RuleEntry<UnicornBetterRegex>;
|
|
6319
6334
|
/**
|
|
6320
6335
|
* Enforce a specific parameter name in catch clauses.
|
|
6321
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6336
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/catch-error-name.md
|
|
6322
6337
|
*/
|
|
6323
6338
|
'unicorn/catch-error-name'?: Linter.RuleEntry<UnicornCatchErrorName>;
|
|
6324
6339
|
/**
|
|
6325
6340
|
* Enforce consistent assertion style with `node:assert`.
|
|
6326
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6341
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-assert.md
|
|
6327
6342
|
*/
|
|
6328
6343
|
'unicorn/consistent-assert'?: Linter.RuleEntry<[]>;
|
|
6329
6344
|
/**
|
|
6330
6345
|
* Prefer passing `Date` directly to the constructor when cloning.
|
|
6331
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6346
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-date-clone.md
|
|
6332
6347
|
*/
|
|
6333
6348
|
'unicorn/consistent-date-clone'?: Linter.RuleEntry<[]>;
|
|
6334
6349
|
/**
|
|
6335
6350
|
* Use destructured variables over properties.
|
|
6336
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6351
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-destructuring.md
|
|
6337
6352
|
*/
|
|
6338
6353
|
'unicorn/consistent-destructuring'?: Linter.RuleEntry<[]>;
|
|
6339
6354
|
/**
|
|
6340
6355
|
* Prefer consistent types when spreading a ternary in an array literal.
|
|
6341
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6356
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-empty-array-spread.md
|
|
6342
6357
|
*/
|
|
6343
6358
|
'unicorn/consistent-empty-array-spread'?: Linter.RuleEntry<[]>;
|
|
6344
6359
|
/**
|
|
6345
6360
|
* Enforce consistent style for element existence checks with `indexOf()`, `lastIndexOf()`, `findIndex()`, and `findLastIndex()`.
|
|
6346
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6361
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-existence-index-check.md
|
|
6347
6362
|
*/
|
|
6348
6363
|
'unicorn/consistent-existence-index-check'?: Linter.RuleEntry<[]>;
|
|
6349
6364
|
/**
|
|
6350
6365
|
* Move function definitions to the highest possible scope.
|
|
6351
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6366
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-function-scoping.md
|
|
6352
6367
|
*/
|
|
6353
6368
|
'unicorn/consistent-function-scoping'?: Linter.RuleEntry<UnicornConsistentFunctionScoping>;
|
|
6369
|
+
/**
|
|
6370
|
+
* Enforce consistent style for escaping `${` in template literals.
|
|
6371
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/consistent-template-literal-escape.md
|
|
6372
|
+
*/
|
|
6373
|
+
'unicorn/consistent-template-literal-escape'?: Linter.RuleEntry<[]>;
|
|
6354
6374
|
/**
|
|
6355
6375
|
* Enforce correct `Error` subclassing.
|
|
6356
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6376
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/custom-error-definition.md
|
|
6357
6377
|
*/
|
|
6358
6378
|
'unicorn/custom-error-definition'?: Linter.RuleEntry<[]>;
|
|
6359
6379
|
/**
|
|
6360
6380
|
* Enforce no spaces between braces.
|
|
6361
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6381
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/empty-brace-spaces.md
|
|
6362
6382
|
*/
|
|
6363
6383
|
'unicorn/empty-brace-spaces'?: Linter.RuleEntry<[]>;
|
|
6364
6384
|
/**
|
|
6365
6385
|
* Enforce passing a `message` value when creating a built-in error.
|
|
6366
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6386
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/error-message.md
|
|
6367
6387
|
*/
|
|
6368
6388
|
'unicorn/error-message'?: Linter.RuleEntry<[]>;
|
|
6369
6389
|
/**
|
|
6370
6390
|
* Require escape sequences to use uppercase or lowercase values.
|
|
6371
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6391
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/escape-case.md
|
|
6372
6392
|
*/
|
|
6373
6393
|
'unicorn/escape-case'?: Linter.RuleEntry<UnicornEscapeCase>;
|
|
6374
6394
|
/**
|
|
6375
6395
|
* Add expiration conditions to TODO comments.
|
|
6376
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6396
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/expiring-todo-comments.md
|
|
6377
6397
|
*/
|
|
6378
6398
|
'unicorn/expiring-todo-comments'?: Linter.RuleEntry<UnicornExpiringTodoComments>;
|
|
6379
6399
|
/**
|
|
6380
6400
|
* Enforce explicitly comparing the `length` or `size` property of a value.
|
|
6381
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6401
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/explicit-length-check.md
|
|
6382
6402
|
*/
|
|
6383
6403
|
'unicorn/explicit-length-check'?: Linter.RuleEntry<UnicornExplicitLengthCheck>;
|
|
6384
6404
|
/**
|
|
6385
6405
|
* Enforce a case style for filenames.
|
|
6386
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6406
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/filename-case.md
|
|
6387
6407
|
*/
|
|
6388
6408
|
'unicorn/filename-case'?: Linter.RuleEntry<UnicornFilenameCase>;
|
|
6389
6409
|
/**
|
|
6390
6410
|
* Enforce specific import styles per module.
|
|
6391
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6411
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/import-style.md
|
|
6392
6412
|
*/
|
|
6393
6413
|
'unicorn/import-style'?: Linter.RuleEntry<UnicornImportStyle>;
|
|
6394
6414
|
/**
|
|
6395
6415
|
* Prevent usage of variables from outside the scope of isolated functions.
|
|
6396
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6416
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/isolated-functions.md
|
|
6397
6417
|
*/
|
|
6398
6418
|
'unicorn/isolated-functions'?: Linter.RuleEntry<UnicornIsolatedFunctions>;
|
|
6399
6419
|
/**
|
|
6400
6420
|
* Enforce the use of `new` for all builtins, except `String`, `Number`, `Boolean`, `Symbol` and `BigInt`.
|
|
6401
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6421
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/new-for-builtins.md
|
|
6402
6422
|
*/
|
|
6403
6423
|
'unicorn/new-for-builtins'?: Linter.RuleEntry<[]>;
|
|
6404
6424
|
/**
|
|
6405
6425
|
* Enforce specifying rules to disable in `eslint-disable` comments.
|
|
6406
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6426
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-abusive-eslint-disable.md
|
|
6407
6427
|
*/
|
|
6408
6428
|
'unicorn/no-abusive-eslint-disable'?: Linter.RuleEntry<[]>;
|
|
6409
6429
|
/**
|
|
6410
6430
|
* Disallow recursive access to `this` within getters and setters.
|
|
6411
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6431
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-accessor-recursion.md
|
|
6412
6432
|
*/
|
|
6413
6433
|
'unicorn/no-accessor-recursion'?: Linter.RuleEntry<[]>;
|
|
6414
6434
|
/**
|
|
6415
6435
|
* Disallow anonymous functions and classes as the default export.
|
|
6416
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6436
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-anonymous-default-export.md
|
|
6417
6437
|
*/
|
|
6418
6438
|
'unicorn/no-anonymous-default-export'?: Linter.RuleEntry<[]>;
|
|
6419
6439
|
/**
|
|
6420
6440
|
* Prevent passing a function reference directly to iterator methods.
|
|
6421
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6441
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-array-callback-reference.md
|
|
6422
6442
|
*/
|
|
6423
6443
|
'unicorn/no-array-callback-reference'?: Linter.RuleEntry<[]>;
|
|
6424
6444
|
/**
|
|
6425
6445
|
* Prefer `for…of` over the `forEach` method.
|
|
6426
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6446
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-array-for-each.md
|
|
6427
6447
|
*/
|
|
6428
6448
|
'unicorn/no-array-for-each'?: Linter.RuleEntry<[]>;
|
|
6429
6449
|
/**
|
|
6430
6450
|
* Disallow using the `this` argument in array methods.
|
|
6431
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6451
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-array-method-this-argument.md
|
|
6432
6452
|
*/
|
|
6433
6453
|
'unicorn/no-array-method-this-argument'?: Linter.RuleEntry<[]>;
|
|
6434
6454
|
/**
|
|
6435
6455
|
* Replaced by `unicorn/prefer-single-call` which covers more cases.
|
|
6436
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6456
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/deleted-and-deprecated-rules.md#no-array-push-push
|
|
6437
6457
|
* @deprecated
|
|
6438
6458
|
*/
|
|
6439
6459
|
'unicorn/no-array-push-push'?: Linter.RuleEntry<[]>;
|
|
6440
6460
|
/**
|
|
6441
6461
|
* Disallow `Array#reduce()` and `Array#reduceRight()`.
|
|
6442
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6462
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-array-reduce.md
|
|
6443
6463
|
*/
|
|
6444
6464
|
'unicorn/no-array-reduce'?: Linter.RuleEntry<UnicornNoArrayReduce>;
|
|
6445
6465
|
/**
|
|
6446
6466
|
* Prefer `Array#toReversed()` over `Array#reverse()`.
|
|
6447
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6467
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-array-reverse.md
|
|
6448
6468
|
*/
|
|
6449
6469
|
'unicorn/no-array-reverse'?: Linter.RuleEntry<UnicornNoArrayReverse>;
|
|
6450
6470
|
/**
|
|
6451
6471
|
* Prefer `Array#toSorted()` over `Array#sort()`.
|
|
6452
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6472
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-array-sort.md
|
|
6453
6473
|
*/
|
|
6454
6474
|
'unicorn/no-array-sort'?: Linter.RuleEntry<UnicornNoArraySort>;
|
|
6455
6475
|
/**
|
|
6456
6476
|
* Disallow member access from await expression.
|
|
6457
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6477
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-await-expression-member.md
|
|
6458
6478
|
*/
|
|
6459
6479
|
'unicorn/no-await-expression-member'?: Linter.RuleEntry<[]>;
|
|
6460
6480
|
/**
|
|
6461
6481
|
* Disallow using `await` in `Promise` method parameters.
|
|
6462
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6482
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-await-in-promise-methods.md
|
|
6463
6483
|
*/
|
|
6464
6484
|
'unicorn/no-await-in-promise-methods'?: Linter.RuleEntry<[]>;
|
|
6465
6485
|
/**
|
|
6466
6486
|
* Do not use leading/trailing space between `console.log` parameters.
|
|
6467
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6487
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-console-spaces.md
|
|
6468
6488
|
*/
|
|
6469
6489
|
'unicorn/no-console-spaces'?: Linter.RuleEntry<[]>;
|
|
6470
6490
|
/**
|
|
6471
6491
|
* Do not use `document.cookie` directly.
|
|
6472
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6492
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-document-cookie.md
|
|
6473
6493
|
*/
|
|
6474
6494
|
'unicorn/no-document-cookie'?: Linter.RuleEntry<[]>;
|
|
6475
6495
|
/**
|
|
6476
6496
|
* Disallow empty files.
|
|
6477
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6497
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-empty-file.md
|
|
6478
6498
|
*/
|
|
6479
6499
|
'unicorn/no-empty-file'?: Linter.RuleEntry<[]>;
|
|
6480
6500
|
/**
|
|
6481
6501
|
* Do not use a `for` loop that can be replaced with a `for-of` loop.
|
|
6482
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6502
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-for-loop.md
|
|
6483
6503
|
*/
|
|
6484
6504
|
'unicorn/no-for-loop'?: Linter.RuleEntry<[]>;
|
|
6485
6505
|
/**
|
|
6486
6506
|
* Enforce the use of Unicode escapes instead of hexadecimal escapes.
|
|
6487
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6507
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-hex-escape.md
|
|
6488
6508
|
*/
|
|
6489
6509
|
'unicorn/no-hex-escape'?: Linter.RuleEntry<[]>;
|
|
6490
6510
|
/**
|
|
6491
6511
|
* Disallow immediate mutation after variable assignment.
|
|
6492
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6512
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-immediate-mutation.md
|
|
6493
6513
|
*/
|
|
6494
6514
|
'unicorn/no-immediate-mutation'?: Linter.RuleEntry<[]>;
|
|
6495
6515
|
/**
|
|
6496
6516
|
* Replaced by `unicorn/no-instanceof-builtins` which covers more cases.
|
|
6497
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6517
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/deleted-and-deprecated-rules.md#no-instanceof-array
|
|
6498
6518
|
* @deprecated
|
|
6499
6519
|
*/
|
|
6500
6520
|
'unicorn/no-instanceof-array'?: Linter.RuleEntry<[]>;
|
|
6501
6521
|
/**
|
|
6502
6522
|
* Disallow `instanceof` with built-in objects
|
|
6503
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6523
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-instanceof-builtins.md
|
|
6504
6524
|
*/
|
|
6505
6525
|
'unicorn/no-instanceof-builtins'?: Linter.RuleEntry<UnicornNoInstanceofBuiltins>;
|
|
6506
6526
|
/**
|
|
6507
6527
|
* Disallow invalid options in `fetch()` and `new Request()`.
|
|
6508
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6528
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-invalid-fetch-options.md
|
|
6509
6529
|
*/
|
|
6510
6530
|
'unicorn/no-invalid-fetch-options'?: Linter.RuleEntry<[]>;
|
|
6511
6531
|
/**
|
|
6512
6532
|
* Prevent calling `EventTarget#removeEventListener()` with the result of an expression.
|
|
6513
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6533
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-invalid-remove-event-listener.md
|
|
6514
6534
|
*/
|
|
6515
6535
|
'unicorn/no-invalid-remove-event-listener'?: Linter.RuleEntry<[]>;
|
|
6516
6536
|
/**
|
|
6517
6537
|
* Disallow identifiers starting with `new` or `class`.
|
|
6518
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6538
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-keyword-prefix.md
|
|
6519
6539
|
*/
|
|
6520
6540
|
'unicorn/no-keyword-prefix'?: Linter.RuleEntry<UnicornNoKeywordPrefix>;
|
|
6521
6541
|
/**
|
|
6522
6542
|
* Replaced by `unicorn/no-unnecessary-slice-end` which covers more cases.
|
|
6523
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6543
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/deleted-and-deprecated-rules.md#no-length-as-slice-end
|
|
6524
6544
|
* @deprecated
|
|
6525
6545
|
*/
|
|
6526
6546
|
'unicorn/no-length-as-slice-end'?: Linter.RuleEntry<[]>;
|
|
6527
6547
|
/**
|
|
6528
6548
|
* Disallow `if` statements as the only statement in `if` blocks without `else`.
|
|
6529
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6549
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-lonely-if.md
|
|
6530
6550
|
*/
|
|
6531
6551
|
'unicorn/no-lonely-if'?: Linter.RuleEntry<[]>;
|
|
6532
6552
|
/**
|
|
6533
6553
|
* Disallow a magic number as the `depth` argument in `Array#flat(…).`
|
|
6534
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6554
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-magic-array-flat-depth.md
|
|
6535
6555
|
*/
|
|
6536
6556
|
'unicorn/no-magic-array-flat-depth'?: Linter.RuleEntry<[]>;
|
|
6537
6557
|
/**
|
|
6538
6558
|
* Disallow named usage of default import and export.
|
|
6539
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6559
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-named-default.md
|
|
6540
6560
|
*/
|
|
6541
6561
|
'unicorn/no-named-default'?: Linter.RuleEntry<[]>;
|
|
6542
6562
|
/**
|
|
6543
6563
|
* Disallow negated conditions.
|
|
6544
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6564
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-negated-condition.md
|
|
6545
6565
|
*/
|
|
6546
6566
|
'unicorn/no-negated-condition'?: Linter.RuleEntry<[]>;
|
|
6547
6567
|
/**
|
|
6548
6568
|
* Disallow negated expression in equality check.
|
|
6549
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6569
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-negation-in-equality-check.md
|
|
6550
6570
|
*/
|
|
6551
6571
|
'unicorn/no-negation-in-equality-check'?: Linter.RuleEntry<[]>;
|
|
6552
6572
|
/**
|
|
6553
6573
|
* Disallow nested ternary expressions.
|
|
6554
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6574
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-nested-ternary.md
|
|
6555
6575
|
*/
|
|
6556
6576
|
'unicorn/no-nested-ternary'?: Linter.RuleEntry<[]>;
|
|
6557
6577
|
/**
|
|
6558
6578
|
* Disallow `new Array()`.
|
|
6559
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6579
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-new-array.md
|
|
6560
6580
|
*/
|
|
6561
6581
|
'unicorn/no-new-array'?: Linter.RuleEntry<[]>;
|
|
6562
6582
|
/**
|
|
6563
6583
|
* Enforce the use of `Buffer.from()` and `Buffer.alloc()` instead of the deprecated `new Buffer()`.
|
|
6564
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6584
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-new-buffer.md
|
|
6565
6585
|
*/
|
|
6566
6586
|
'unicorn/no-new-buffer'?: Linter.RuleEntry<[]>;
|
|
6567
6587
|
/**
|
|
6568
6588
|
* Disallow the use of the `null` literal.
|
|
6569
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6589
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-null.md
|
|
6570
6590
|
*/
|
|
6571
6591
|
'unicorn/no-null'?: Linter.RuleEntry<UnicornNoNull>;
|
|
6572
6592
|
/**
|
|
6573
6593
|
* Disallow the use of objects as default parameters.
|
|
6574
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6594
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-object-as-default-parameter.md
|
|
6575
6595
|
*/
|
|
6576
6596
|
'unicorn/no-object-as-default-parameter'?: Linter.RuleEntry<[]>;
|
|
6577
6597
|
/**
|
|
6578
6598
|
* Disallow `process.exit()`.
|
|
6579
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6599
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-process-exit.md
|
|
6580
6600
|
*/
|
|
6581
6601
|
'unicorn/no-process-exit'?: Linter.RuleEntry<[]>;
|
|
6582
6602
|
/**
|
|
6583
6603
|
* Disallow passing single-element arrays to `Promise` methods.
|
|
6584
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6604
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-single-promise-in-promise-methods.md
|
|
6585
6605
|
*/
|
|
6586
6606
|
'unicorn/no-single-promise-in-promise-methods'?: Linter.RuleEntry<[]>;
|
|
6587
6607
|
/**
|
|
6588
6608
|
* Disallow classes that only have static members.
|
|
6589
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6609
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-static-only-class.md
|
|
6590
6610
|
*/
|
|
6591
6611
|
'unicorn/no-static-only-class'?: Linter.RuleEntry<[]>;
|
|
6592
6612
|
/**
|
|
6593
6613
|
* Disallow `then` property.
|
|
6594
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6614
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-thenable.md
|
|
6595
6615
|
*/
|
|
6596
6616
|
'unicorn/no-thenable'?: Linter.RuleEntry<[]>;
|
|
6597
6617
|
/**
|
|
6598
6618
|
* Disallow assigning `this` to a variable.
|
|
6599
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6619
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-this-assignment.md
|
|
6600
6620
|
*/
|
|
6601
6621
|
'unicorn/no-this-assignment'?: Linter.RuleEntry<[]>;
|
|
6602
6622
|
/**
|
|
6603
6623
|
* Disallow comparing `undefined` using `typeof`.
|
|
6604
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6624
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-typeof-undefined.md
|
|
6605
6625
|
*/
|
|
6606
6626
|
'unicorn/no-typeof-undefined'?: Linter.RuleEntry<UnicornNoTypeofUndefined>;
|
|
6607
6627
|
/**
|
|
6608
6628
|
* Disallow using `1` as the `depth` argument of `Array#flat()`.
|
|
6609
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6629
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unnecessary-array-flat-depth.md
|
|
6610
6630
|
*/
|
|
6611
6631
|
'unicorn/no-unnecessary-array-flat-depth'?: Linter.RuleEntry<[]>;
|
|
6612
6632
|
/**
|
|
6613
6633
|
* Disallow using `.length` or `Infinity` as the `deleteCount` or `skipCount` argument of `Array#{splice,toSpliced}()`.
|
|
6614
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6634
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unnecessary-array-splice-count.md
|
|
6615
6635
|
*/
|
|
6616
6636
|
'unicorn/no-unnecessary-array-splice-count'?: Linter.RuleEntry<[]>;
|
|
6617
6637
|
/**
|
|
6618
6638
|
* Disallow awaiting non-promise values.
|
|
6619
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6639
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unnecessary-await.md
|
|
6620
6640
|
*/
|
|
6621
6641
|
'unicorn/no-unnecessary-await'?: Linter.RuleEntry<[]>;
|
|
6622
6642
|
/**
|
|
6623
6643
|
* Enforce the use of built-in methods instead of unnecessary polyfills.
|
|
6624
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6644
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unnecessary-polyfills.md
|
|
6625
6645
|
*/
|
|
6626
6646
|
'unicorn/no-unnecessary-polyfills'?: Linter.RuleEntry<UnicornNoUnnecessaryPolyfills>;
|
|
6627
6647
|
/**
|
|
6628
6648
|
* Disallow using `.length` or `Infinity` as the `end` argument of `{Array,String,TypedArray}#slice()`.
|
|
6629
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6649
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unnecessary-slice-end.md
|
|
6630
6650
|
*/
|
|
6631
6651
|
'unicorn/no-unnecessary-slice-end'?: Linter.RuleEntry<[]>;
|
|
6632
6652
|
/**
|
|
6633
6653
|
* Disallow unreadable array destructuring.
|
|
6634
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6654
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unreadable-array-destructuring.md
|
|
6635
6655
|
*/
|
|
6636
6656
|
'unicorn/no-unreadable-array-destructuring'?: Linter.RuleEntry<[]>;
|
|
6637
6657
|
/**
|
|
6638
6658
|
* Disallow unreadable IIFEs.
|
|
6639
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6659
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unreadable-iife.md
|
|
6640
6660
|
*/
|
|
6641
6661
|
'unicorn/no-unreadable-iife'?: Linter.RuleEntry<[]>;
|
|
6642
6662
|
/**
|
|
6643
6663
|
* Disallow unused object properties.
|
|
6644
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6664
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-unused-properties.md
|
|
6645
6665
|
*/
|
|
6646
6666
|
'unicorn/no-unused-properties'?: Linter.RuleEntry<[]>;
|
|
6647
6667
|
/**
|
|
6648
6668
|
* Disallow useless values or fallbacks in `Set`, `Map`, `WeakSet`, or `WeakMap`.
|
|
6649
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6669
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-collection-argument.md
|
|
6650
6670
|
*/
|
|
6651
6671
|
'unicorn/no-useless-collection-argument'?: Linter.RuleEntry<[]>;
|
|
6652
6672
|
/**
|
|
6653
6673
|
* Disallow unnecessary `Error.captureStackTrace(…)`.
|
|
6654
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6674
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-error-capture-stack-trace.md
|
|
6655
6675
|
*/
|
|
6656
6676
|
'unicorn/no-useless-error-capture-stack-trace'?: Linter.RuleEntry<[]>;
|
|
6657
6677
|
/**
|
|
6658
6678
|
* Disallow useless fallback when spreading in object literals.
|
|
6659
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6679
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-fallback-in-spread.md
|
|
6660
6680
|
*/
|
|
6661
6681
|
'unicorn/no-useless-fallback-in-spread'?: Linter.RuleEntry<[]>;
|
|
6682
|
+
/**
|
|
6683
|
+
* Disallow unnecessary `.toArray()` on iterators.
|
|
6684
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-iterator-to-array.md
|
|
6685
|
+
*/
|
|
6686
|
+
'unicorn/no-useless-iterator-to-array'?: Linter.RuleEntry<[]>;
|
|
6662
6687
|
/**
|
|
6663
6688
|
* Disallow useless array length check.
|
|
6664
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6689
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-length-check.md
|
|
6665
6690
|
*/
|
|
6666
6691
|
'unicorn/no-useless-length-check'?: Linter.RuleEntry<[]>;
|
|
6667
6692
|
/**
|
|
6668
6693
|
* Disallow returning/yielding `Promise.resolve/reject()` in async functions or promise callbacks
|
|
6669
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6694
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-promise-resolve-reject.md
|
|
6670
6695
|
*/
|
|
6671
6696
|
'unicorn/no-useless-promise-resolve-reject'?: Linter.RuleEntry<[]>;
|
|
6672
6697
|
/**
|
|
6673
6698
|
* Disallow unnecessary spread.
|
|
6674
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6699
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-spread.md
|
|
6675
6700
|
*/
|
|
6676
6701
|
'unicorn/no-useless-spread'?: Linter.RuleEntry<[]>;
|
|
6677
6702
|
/**
|
|
6678
6703
|
* Disallow useless case in switch statements.
|
|
6679
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6704
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-switch-case.md
|
|
6680
6705
|
*/
|
|
6681
6706
|
'unicorn/no-useless-switch-case'?: Linter.RuleEntry<[]>;
|
|
6682
6707
|
/**
|
|
6683
6708
|
* Disallow useless `undefined`.
|
|
6684
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6709
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-useless-undefined.md
|
|
6685
6710
|
*/
|
|
6686
6711
|
'unicorn/no-useless-undefined'?: Linter.RuleEntry<UnicornNoUselessUndefined>;
|
|
6687
6712
|
/**
|
|
6688
6713
|
* Disallow number literals with zero fractions or dangling dots.
|
|
6689
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6714
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/no-zero-fractions.md
|
|
6690
6715
|
*/
|
|
6691
6716
|
'unicorn/no-zero-fractions'?: Linter.RuleEntry<[]>;
|
|
6692
6717
|
/**
|
|
6693
6718
|
* Enforce proper case for numeric literals.
|
|
6694
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6719
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/number-literal-case.md
|
|
6695
6720
|
*/
|
|
6696
6721
|
'unicorn/number-literal-case'?: Linter.RuleEntry<UnicornNumberLiteralCase>;
|
|
6697
6722
|
/**
|
|
6698
6723
|
* Enforce the style of numeric separators by correctly grouping digits.
|
|
6699
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6724
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/numeric-separators-style.md
|
|
6700
6725
|
*/
|
|
6701
6726
|
'unicorn/numeric-separators-style'?: Linter.RuleEntry<UnicornNumericSeparatorsStyle>;
|
|
6702
6727
|
/**
|
|
6703
6728
|
* Prefer `.addEventListener()` and `.removeEventListener()` over `on`-functions.
|
|
6704
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6729
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-add-event-listener.md
|
|
6705
6730
|
*/
|
|
6706
6731
|
'unicorn/prefer-add-event-listener'?: Linter.RuleEntry<UnicornPreferAddEventListener>;
|
|
6707
6732
|
/**
|
|
6708
6733
|
* Prefer `.find(…)` and `.findLast(…)` over the first or last element from `.filter(…)`.
|
|
6709
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6734
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-array-find.md
|
|
6710
6735
|
*/
|
|
6711
6736
|
'unicorn/prefer-array-find'?: Linter.RuleEntry<UnicornPreferArrayFind>;
|
|
6712
6737
|
/**
|
|
6713
6738
|
* Prefer `Array#flat()` over legacy techniques to flatten arrays.
|
|
6714
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6739
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-array-flat.md
|
|
6715
6740
|
*/
|
|
6716
6741
|
'unicorn/prefer-array-flat'?: Linter.RuleEntry<UnicornPreferArrayFlat>;
|
|
6717
6742
|
/**
|
|
6718
6743
|
* Prefer `.flatMap(…)` over `.map(…).flat()`.
|
|
6719
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6744
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-array-flat-map.md
|
|
6720
6745
|
*/
|
|
6721
6746
|
'unicorn/prefer-array-flat-map'?: Linter.RuleEntry<[]>;
|
|
6722
6747
|
/**
|
|
6723
6748
|
* Prefer `Array#{indexOf,lastIndexOf}()` over `Array#{findIndex,findLastIndex}()` when looking for the index of an item.
|
|
6724
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6749
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-array-index-of.md
|
|
6725
6750
|
*/
|
|
6726
6751
|
'unicorn/prefer-array-index-of'?: Linter.RuleEntry<[]>;
|
|
6727
6752
|
/**
|
|
6728
6753
|
* Prefer `.some(…)` over `.filter(…).length` check and `.{find,findLast,findIndex,findLastIndex}(…)`.
|
|
6729
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6754
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-array-some.md
|
|
6730
6755
|
*/
|
|
6731
6756
|
'unicorn/prefer-array-some'?: Linter.RuleEntry<[]>;
|
|
6732
6757
|
/**
|
|
6733
6758
|
* Prefer `.at()` method for index access and `String#charAt()`.
|
|
6734
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6759
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-at.md
|
|
6735
6760
|
*/
|
|
6736
6761
|
'unicorn/prefer-at'?: Linter.RuleEntry<UnicornPreferAt>;
|
|
6737
6762
|
/**
|
|
6738
6763
|
* Prefer `BigInt` literals over the constructor.
|
|
6739
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6764
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-bigint-literals.md
|
|
6740
6765
|
*/
|
|
6741
6766
|
'unicorn/prefer-bigint-literals'?: Linter.RuleEntry<[]>;
|
|
6742
6767
|
/**
|
|
6743
6768
|
* Prefer `Blob#arrayBuffer()` over `FileReader#readAsArrayBuffer(…)` and `Blob#text()` over `FileReader#readAsText(…)`.
|
|
6744
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6769
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-blob-reading-methods.md
|
|
6745
6770
|
*/
|
|
6746
6771
|
'unicorn/prefer-blob-reading-methods'?: Linter.RuleEntry<[]>;
|
|
6747
6772
|
/**
|
|
6748
6773
|
* Prefer class field declarations over `this` assignments in constructors.
|
|
6749
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6774
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-class-fields.md
|
|
6750
6775
|
*/
|
|
6751
6776
|
'unicorn/prefer-class-fields'?: Linter.RuleEntry<[]>;
|
|
6752
6777
|
/**
|
|
6753
6778
|
* Prefer using `Element#classList.toggle()` to toggle class names.
|
|
6754
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6779
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-classlist-toggle.md
|
|
6755
6780
|
*/
|
|
6756
6781
|
'unicorn/prefer-classlist-toggle'?: Linter.RuleEntry<[]>;
|
|
6757
6782
|
/**
|
|
6758
6783
|
* Prefer `String#codePointAt(…)` over `String#charCodeAt(…)` and `String.fromCodePoint(…)` over `String.fromCharCode(…)`.
|
|
6759
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6784
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-code-point.md
|
|
6760
6785
|
*/
|
|
6761
6786
|
'unicorn/prefer-code-point'?: Linter.RuleEntry<[]>;
|
|
6762
6787
|
/**
|
|
6763
6788
|
* Prefer `Date.now()` to get the number of milliseconds since the Unix Epoch.
|
|
6764
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6789
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-date-now.md
|
|
6765
6790
|
*/
|
|
6766
6791
|
'unicorn/prefer-date-now'?: Linter.RuleEntry<[]>;
|
|
6767
6792
|
/**
|
|
6768
6793
|
* Prefer default parameters over reassignment.
|
|
6769
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6794
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-default-parameters.md
|
|
6770
6795
|
*/
|
|
6771
6796
|
'unicorn/prefer-default-parameters'?: Linter.RuleEntry<[]>;
|
|
6772
6797
|
/**
|
|
6773
6798
|
* Prefer `Node#append()` over `Node#appendChild()`.
|
|
6774
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6799
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-dom-node-append.md
|
|
6775
6800
|
*/
|
|
6776
6801
|
'unicorn/prefer-dom-node-append'?: Linter.RuleEntry<[]>;
|
|
6777
6802
|
/**
|
|
6778
6803
|
* Prefer using `.dataset` on DOM elements over calling attribute methods.
|
|
6779
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6804
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-dom-node-dataset.md
|
|
6780
6805
|
*/
|
|
6781
6806
|
'unicorn/prefer-dom-node-dataset'?: Linter.RuleEntry<[]>;
|
|
6782
6807
|
/**
|
|
6783
6808
|
* Prefer `childNode.remove()` over `parentNode.removeChild(childNode)`.
|
|
6784
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6809
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-dom-node-remove.md
|
|
6785
6810
|
*/
|
|
6786
6811
|
'unicorn/prefer-dom-node-remove'?: Linter.RuleEntry<[]>;
|
|
6787
6812
|
/**
|
|
6788
6813
|
* Prefer `.textContent` over `.innerText`.
|
|
6789
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6814
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-dom-node-text-content.md
|
|
6790
6815
|
*/
|
|
6791
6816
|
'unicorn/prefer-dom-node-text-content'?: Linter.RuleEntry<[]>;
|
|
6792
6817
|
/**
|
|
6793
6818
|
* Prefer `EventTarget` over `EventEmitter`.
|
|
6794
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6819
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-event-target.md
|
|
6795
6820
|
*/
|
|
6796
6821
|
'unicorn/prefer-event-target'?: Linter.RuleEntry<[]>;
|
|
6797
6822
|
/**
|
|
6798
6823
|
* Prefer `export…from` when re-exporting.
|
|
6799
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6824
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-export-from.md
|
|
6800
6825
|
*/
|
|
6801
6826
|
'unicorn/prefer-export-from'?: Linter.RuleEntry<UnicornPreferExportFrom>;
|
|
6802
6827
|
/**
|
|
6803
6828
|
* Prefer `globalThis` over `window`, `self`, and `global`.
|
|
6804
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6829
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-global-this.md
|
|
6805
6830
|
*/
|
|
6806
6831
|
'unicorn/prefer-global-this'?: Linter.RuleEntry<[]>;
|
|
6807
6832
|
/**
|
|
6808
6833
|
* Prefer `import.meta.{dirname,filename}` over legacy techniques for getting file paths.
|
|
6809
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6834
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-import-meta-properties.md
|
|
6810
6835
|
*/
|
|
6811
6836
|
'unicorn/prefer-import-meta-properties'?: Linter.RuleEntry<[]>;
|
|
6812
6837
|
/**
|
|
6813
6838
|
* Prefer `.includes()` over `.indexOf()`, `.lastIndexOf()`, and `Array#some()` when checking for existence or non-existence.
|
|
6814
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6839
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-includes.md
|
|
6815
6840
|
*/
|
|
6816
6841
|
'unicorn/prefer-includes'?: Linter.RuleEntry<[]>;
|
|
6817
6842
|
/**
|
|
6818
6843
|
* Prefer reading a JSON file as a buffer.
|
|
6819
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6844
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-json-parse-buffer.md
|
|
6820
6845
|
*/
|
|
6821
6846
|
'unicorn/prefer-json-parse-buffer'?: Linter.RuleEntry<[]>;
|
|
6822
6847
|
/**
|
|
6823
6848
|
* Prefer `KeyboardEvent#key` over `KeyboardEvent#keyCode`.
|
|
6824
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6849
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-keyboard-event-key.md
|
|
6825
6850
|
*/
|
|
6826
6851
|
'unicorn/prefer-keyboard-event-key'?: Linter.RuleEntry<[]>;
|
|
6827
6852
|
/**
|
|
6828
6853
|
* Prefer using a logical operator over a ternary.
|
|
6829
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6854
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-logical-operator-over-ternary.md
|
|
6830
6855
|
*/
|
|
6831
6856
|
'unicorn/prefer-logical-operator-over-ternary'?: Linter.RuleEntry<[]>;
|
|
6832
6857
|
/**
|
|
6833
6858
|
* Prefer `Math.min()` and `Math.max()` over ternaries for simple comparisons.
|
|
6834
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6859
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-math-min-max.md
|
|
6835
6860
|
*/
|
|
6836
6861
|
'unicorn/prefer-math-min-max'?: Linter.RuleEntry<[]>;
|
|
6837
6862
|
/**
|
|
6838
6863
|
* Enforce the use of `Math.trunc` instead of bitwise operators.
|
|
6839
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6864
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-math-trunc.md
|
|
6840
6865
|
*/
|
|
6841
6866
|
'unicorn/prefer-math-trunc'?: Linter.RuleEntry<[]>;
|
|
6842
6867
|
/**
|
|
6843
6868
|
* Prefer `.before()` over `.insertBefore()`, `.replaceWith()` over `.replaceChild()`, prefer one of `.before()`, `.after()`, `.append()` or `.prepend()` over `insertAdjacentText()` and `insertAdjacentElement()`.
|
|
6844
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6869
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-modern-dom-apis.md
|
|
6845
6870
|
*/
|
|
6846
6871
|
'unicorn/prefer-modern-dom-apis'?: Linter.RuleEntry<[]>;
|
|
6847
6872
|
/**
|
|
6848
6873
|
* Prefer modern `Math` APIs over legacy patterns.
|
|
6849
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6874
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-modern-math-apis.md
|
|
6850
6875
|
*/
|
|
6851
6876
|
'unicorn/prefer-modern-math-apis'?: Linter.RuleEntry<[]>;
|
|
6852
6877
|
/**
|
|
6853
6878
|
* Prefer JavaScript modules (ESM) over CommonJS.
|
|
6854
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6879
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-module.md
|
|
6855
6880
|
*/
|
|
6856
6881
|
'unicorn/prefer-module'?: Linter.RuleEntry<[]>;
|
|
6857
6882
|
/**
|
|
6858
6883
|
* Prefer using `String`, `Number`, `BigInt`, `Boolean`, and `Symbol` directly.
|
|
6859
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6884
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-native-coercion-functions.md
|
|
6860
6885
|
*/
|
|
6861
6886
|
'unicorn/prefer-native-coercion-functions'?: Linter.RuleEntry<[]>;
|
|
6862
6887
|
/**
|
|
6863
6888
|
* Prefer negative index over `.length - index` when possible.
|
|
6864
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6889
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-negative-index.md
|
|
6865
6890
|
*/
|
|
6866
6891
|
'unicorn/prefer-negative-index'?: Linter.RuleEntry<[]>;
|
|
6867
6892
|
/**
|
|
6868
6893
|
* Prefer using the `node:` protocol when importing Node.js builtin modules.
|
|
6869
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6894
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-node-protocol.md
|
|
6870
6895
|
*/
|
|
6871
6896
|
'unicorn/prefer-node-protocol'?: Linter.RuleEntry<[]>;
|
|
6872
6897
|
/**
|
|
6873
6898
|
* Prefer `Number` static properties over global ones.
|
|
6874
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6899
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-number-properties.md
|
|
6875
6900
|
*/
|
|
6876
6901
|
'unicorn/prefer-number-properties'?: Linter.RuleEntry<UnicornPreferNumberProperties>;
|
|
6877
6902
|
/**
|
|
6878
6903
|
* Prefer using `Object.fromEntries(…)` to transform a list of key-value pairs into an object.
|
|
6879
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6904
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-object-from-entries.md
|
|
6880
6905
|
*/
|
|
6881
6906
|
'unicorn/prefer-object-from-entries'?: Linter.RuleEntry<UnicornPreferObjectFromEntries>;
|
|
6882
6907
|
/**
|
|
6883
6908
|
* Prefer omitting the `catch` binding parameter.
|
|
6884
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6909
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-optional-catch-binding.md
|
|
6885
6910
|
*/
|
|
6886
6911
|
'unicorn/prefer-optional-catch-binding'?: Linter.RuleEntry<[]>;
|
|
6887
6912
|
/**
|
|
6888
6913
|
* Prefer borrowing methods from the prototype instead of the instance.
|
|
6889
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6914
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-prototype-methods.md
|
|
6890
6915
|
*/
|
|
6891
6916
|
'unicorn/prefer-prototype-methods'?: Linter.RuleEntry<[]>;
|
|
6892
6917
|
/**
|
|
6893
6918
|
* Prefer `.querySelector()` over `.getElementById()`, `.querySelectorAll()` over `.getElementsByClassName()` and `.getElementsByTagName()` and `.getElementsByName()`.
|
|
6894
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6919
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-query-selector.md
|
|
6895
6920
|
*/
|
|
6896
6921
|
'unicorn/prefer-query-selector'?: Linter.RuleEntry<[]>;
|
|
6897
6922
|
/**
|
|
6898
6923
|
* Prefer `Reflect.apply()` over `Function#apply()`.
|
|
6899
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6924
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-reflect-apply.md
|
|
6900
6925
|
*/
|
|
6901
6926
|
'unicorn/prefer-reflect-apply'?: Linter.RuleEntry<[]>;
|
|
6902
6927
|
/**
|
|
6903
6928
|
* Prefer `RegExp#test()` over `String#match()` and `RegExp#exec()`.
|
|
6904
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6929
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-regexp-test.md
|
|
6905
6930
|
*/
|
|
6906
6931
|
'unicorn/prefer-regexp-test'?: Linter.RuleEntry<[]>;
|
|
6907
6932
|
/**
|
|
6908
6933
|
* Prefer `Response.json()` over `new Response(JSON.stringify())`.
|
|
6909
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6934
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-response-static-json.md
|
|
6910
6935
|
*/
|
|
6911
6936
|
'unicorn/prefer-response-static-json'?: Linter.RuleEntry<[]>;
|
|
6912
6937
|
/**
|
|
6913
6938
|
* Prefer `Set#has()` over `Array#includes()` when checking for existence or non-existence.
|
|
6914
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6939
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-set-has.md
|
|
6915
6940
|
*/
|
|
6916
6941
|
'unicorn/prefer-set-has'?: Linter.RuleEntry<[]>;
|
|
6917
6942
|
/**
|
|
6918
6943
|
* Prefer using `Set#size` instead of `Array#length`.
|
|
6919
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6944
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-set-size.md
|
|
6920
6945
|
*/
|
|
6921
6946
|
'unicorn/prefer-set-size'?: Linter.RuleEntry<[]>;
|
|
6947
|
+
/**
|
|
6948
|
+
* Prefer simple conditions first in logical expressions.
|
|
6949
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-simple-condition-first.md
|
|
6950
|
+
*/
|
|
6951
|
+
'unicorn/prefer-simple-condition-first'?: Linter.RuleEntry<[]>;
|
|
6922
6952
|
/**
|
|
6923
6953
|
* Enforce combining multiple `Array#push()`, `Element#classList.{add,remove}()`, and `importScripts()` into one call.
|
|
6924
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6954
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-single-call.md
|
|
6925
6955
|
*/
|
|
6926
6956
|
'unicorn/prefer-single-call'?: Linter.RuleEntry<UnicornPreferSingleCall>;
|
|
6927
6957
|
/**
|
|
6928
6958
|
* Prefer the spread operator over `Array.from(…)`, `Array#concat(…)`, `Array#{slice,toSpliced}()` and `String#split('')`.
|
|
6929
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6959
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-spread.md
|
|
6930
6960
|
*/
|
|
6931
6961
|
'unicorn/prefer-spread'?: Linter.RuleEntry<[]>;
|
|
6932
6962
|
/**
|
|
6933
6963
|
* Prefer using the `String.raw` tag to avoid escaping `\`.
|
|
6934
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6964
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-string-raw.md
|
|
6935
6965
|
*/
|
|
6936
6966
|
'unicorn/prefer-string-raw'?: Linter.RuleEntry<[]>;
|
|
6937
6967
|
/**
|
|
6938
6968
|
* Prefer `String#replaceAll()` over regex searches with the global flag.
|
|
6939
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6969
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-string-replace-all.md
|
|
6940
6970
|
*/
|
|
6941
6971
|
'unicorn/prefer-string-replace-all'?: Linter.RuleEntry<[]>;
|
|
6942
6972
|
/**
|
|
6943
6973
|
* Prefer `String#slice()` over `String#substr()` and `String#substring()`.
|
|
6944
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6974
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-string-slice.md
|
|
6945
6975
|
*/
|
|
6946
6976
|
'unicorn/prefer-string-slice'?: Linter.RuleEntry<[]>;
|
|
6947
6977
|
/**
|
|
6948
6978
|
* Prefer `String#startsWith()` & `String#endsWith()` over `RegExp#test()`.
|
|
6949
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6979
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-string-starts-ends-with.md
|
|
6950
6980
|
*/
|
|
6951
6981
|
'unicorn/prefer-string-starts-ends-with'?: Linter.RuleEntry<[]>;
|
|
6952
6982
|
/**
|
|
6953
6983
|
* Prefer `String#trimStart()` / `String#trimEnd()` over `String#trimLeft()` / `String#trimRight()`.
|
|
6954
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6984
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-string-trim-start-end.md
|
|
6955
6985
|
*/
|
|
6956
6986
|
'unicorn/prefer-string-trim-start-end'?: Linter.RuleEntry<[]>;
|
|
6957
6987
|
/**
|
|
6958
6988
|
* Prefer using `structuredClone` to create a deep clone.
|
|
6959
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6989
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-structured-clone.md
|
|
6960
6990
|
*/
|
|
6961
6991
|
'unicorn/prefer-structured-clone'?: Linter.RuleEntry<UnicornPreferStructuredClone>;
|
|
6962
6992
|
/**
|
|
6963
6993
|
* Prefer `switch` over multiple `else-if`.
|
|
6964
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6994
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-switch.md
|
|
6965
6995
|
*/
|
|
6966
6996
|
'unicorn/prefer-switch'?: Linter.RuleEntry<UnicornPreferSwitch>;
|
|
6967
6997
|
/**
|
|
6968
6998
|
* Prefer ternary expressions over simple `if-else` statements.
|
|
6969
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6999
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-ternary.md
|
|
6970
7000
|
*/
|
|
6971
7001
|
'unicorn/prefer-ternary'?: Linter.RuleEntry<UnicornPreferTernary>;
|
|
6972
7002
|
/**
|
|
6973
7003
|
* Prefer top-level await over top-level promises and async function calls.
|
|
6974
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7004
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-top-level-await.md
|
|
6975
7005
|
*/
|
|
6976
7006
|
'unicorn/prefer-top-level-await'?: Linter.RuleEntry<[]>;
|
|
6977
7007
|
/**
|
|
6978
7008
|
* Enforce throwing `TypeError` in type checking conditions.
|
|
6979
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7009
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prefer-type-error.md
|
|
6980
7010
|
*/
|
|
6981
7011
|
'unicorn/prefer-type-error'?: Linter.RuleEntry<[]>;
|
|
6982
7012
|
/**
|
|
6983
7013
|
* Prevent abbreviations.
|
|
6984
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7014
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/prevent-abbreviations.md
|
|
6985
7015
|
*/
|
|
6986
7016
|
'unicorn/prevent-abbreviations'?: Linter.RuleEntry<UnicornPreventAbbreviations>;
|
|
6987
7017
|
/**
|
|
6988
7018
|
* Enforce consistent relative URL style.
|
|
6989
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7019
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/relative-url-style.md
|
|
6990
7020
|
*/
|
|
6991
7021
|
'unicorn/relative-url-style'?: Linter.RuleEntry<UnicornRelativeUrlStyle>;
|
|
6992
7022
|
/**
|
|
6993
7023
|
* Enforce using the separator argument with `Array#join()`.
|
|
6994
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7024
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/require-array-join-separator.md
|
|
6995
7025
|
*/
|
|
6996
7026
|
'unicorn/require-array-join-separator'?: Linter.RuleEntry<[]>;
|
|
6997
7027
|
/**
|
|
6998
7028
|
* Require non-empty module attributes for imports and exports
|
|
6999
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7029
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/require-module-attributes.md
|
|
7000
7030
|
*/
|
|
7001
7031
|
'unicorn/require-module-attributes'?: Linter.RuleEntry<[]>;
|
|
7002
7032
|
/**
|
|
7003
7033
|
* Require non-empty specifier list in import and export statements.
|
|
7004
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7034
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/require-module-specifiers.md
|
|
7005
7035
|
*/
|
|
7006
7036
|
'unicorn/require-module-specifiers'?: Linter.RuleEntry<[]>;
|
|
7007
7037
|
/**
|
|
7008
7038
|
* Enforce using the digits argument with `Number#toFixed()`.
|
|
7009
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7039
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/require-number-to-fixed-digits-argument.md
|
|
7010
7040
|
*/
|
|
7011
7041
|
'unicorn/require-number-to-fixed-digits-argument'?: Linter.RuleEntry<[]>;
|
|
7012
7042
|
/**
|
|
7013
7043
|
* Enforce using the `targetOrigin` argument with `window.postMessage()`.
|
|
7014
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7044
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/require-post-message-target-origin.md
|
|
7015
7045
|
*/
|
|
7016
7046
|
'unicorn/require-post-message-target-origin'?: Linter.RuleEntry<[]>;
|
|
7017
7047
|
/**
|
|
7018
7048
|
* Enforce better string content.
|
|
7019
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7049
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/string-content.md
|
|
7020
7050
|
*/
|
|
7021
7051
|
'unicorn/string-content'?: Linter.RuleEntry<UnicornStringContent>;
|
|
7022
7052
|
/**
|
|
7023
7053
|
* Enforce consistent brace style for `case` clauses.
|
|
7024
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7054
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/switch-case-braces.md
|
|
7025
7055
|
*/
|
|
7026
7056
|
'unicorn/switch-case-braces'?: Linter.RuleEntry<UnicornSwitchCaseBraces>;
|
|
7057
|
+
/**
|
|
7058
|
+
* Enforce consistent `break`/`return`/`continue`/`throw` position in `case` clauses.
|
|
7059
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/switch-case-break-position.md
|
|
7060
|
+
*/
|
|
7061
|
+
'unicorn/switch-case-break-position'?: Linter.RuleEntry<[]>;
|
|
7027
7062
|
/**
|
|
7028
7063
|
* Fix whitespace-insensitive template indentation.
|
|
7029
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7064
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/template-indent.md
|
|
7030
7065
|
*/
|
|
7031
7066
|
'unicorn/template-indent'?: Linter.RuleEntry<UnicornTemplateIndent>;
|
|
7032
7067
|
/**
|
|
7033
7068
|
* Enforce consistent case for text encoding identifiers.
|
|
7034
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7069
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/text-encoding-identifier-case.md
|
|
7035
7070
|
*/
|
|
7036
7071
|
'unicorn/text-encoding-identifier-case'?: Linter.RuleEntry<UnicornTextEncodingIdentifierCase>;
|
|
7037
7072
|
/**
|
|
7038
7073
|
* Require `new` when creating an error.
|
|
7039
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
7074
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v64.0.0/docs/rules/throw-new-error.md
|
|
7040
7075
|
*/
|
|
7041
7076
|
'unicorn/throw-new-error'?: Linter.RuleEntry<[]>;
|
|
7042
7077
|
/**
|
|
@@ -7455,6 +7490,11 @@ interface RuleOptions {
|
|
|
7455
7490
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/require-top-level-describe.md
|
|
7456
7491
|
*/
|
|
7457
7492
|
'vitest/require-top-level-describe'?: Linter.RuleEntry<VitestRequireTopLevelDescribe>;
|
|
7493
|
+
/**
|
|
7494
|
+
* enforce unbound methods are called with their expected scope
|
|
7495
|
+
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/unbound-method.md
|
|
7496
|
+
*/
|
|
7497
|
+
'vitest/unbound-method'?: Linter.RuleEntry<VitestUnboundMethod>;
|
|
7458
7498
|
/**
|
|
7459
7499
|
* enforce valid describe callback
|
|
7460
7500
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/valid-describe-callback.md
|
|
@@ -11602,13 +11642,15 @@ type LogicalAssignmentOperators = (([] | ["always"] | ["always", {
|
|
|
11602
11642
|
}] | ["never"]) & unknown[]); // ----- markdown/fenced-code-language -----
|
|
11603
11643
|
type MarkdownFencedCodeLanguage = [] | [{
|
|
11604
11644
|
required?: string[];
|
|
11605
|
-
}]; // ----- markdown/
|
|
11645
|
+
}]; // ----- markdown/fenced-code-meta -----
|
|
11646
|
+
type MarkdownFencedCodeMeta = [] | [("always" | "never")]; // ----- markdown/heading-increment -----
|
|
11606
11647
|
type MarkdownHeadingIncrement = [] | [{
|
|
11607
11648
|
frontmatterTitle?: string;
|
|
11608
11649
|
}]; // ----- markdown/no-duplicate-definitions -----
|
|
11609
11650
|
type MarkdownNoDuplicateDefinitions = [] | [{
|
|
11610
11651
|
allowDefinitions?: string[];
|
|
11611
11652
|
allowFootnoteDefinitions?: string[];
|
|
11653
|
+
checkFootnoteDefinitions?: boolean;
|
|
11612
11654
|
}]; // ----- markdown/no-duplicate-headings -----
|
|
11613
11655
|
type MarkdownNoDuplicateHeadings = [] | [{
|
|
11614
11656
|
checkSiblingsOnly?: boolean;
|
|
@@ -11641,6 +11683,7 @@ type MarkdownNoSpaceInEmphasis = [] | [{
|
|
|
11641
11683
|
type MarkdownNoUnusedDefinitions = [] | [{
|
|
11642
11684
|
allowDefinitions?: string[];
|
|
11643
11685
|
allowFootnoteDefinitions?: string[];
|
|
11686
|
+
checkFootnoteDefinitions?: boolean;
|
|
11644
11687
|
}]; // ----- markdown/table-column-count -----
|
|
11645
11688
|
type MarkdownTableColumnCount = [] | [{
|
|
11646
11689
|
checkMissingCells?: boolean;
|
|
@@ -12613,6 +12656,7 @@ type PerfectionistSortArrayIncludes = {
|
|
|
12613
12656
|
pattern: string;
|
|
12614
12657
|
flags?: string;
|
|
12615
12658
|
} | string));
|
|
12659
|
+
matchesAstSelector?: string;
|
|
12616
12660
|
};
|
|
12617
12661
|
partitionByComment?: (boolean | (({
|
|
12618
12662
|
pattern: string;
|
|
@@ -12638,7 +12682,7 @@ type PerfectionistSortArrayIncludes = {
|
|
|
12638
12682
|
});
|
|
12639
12683
|
partitionByNewLine?: boolean;
|
|
12640
12684
|
}[]; // ----- perfectionist/sort-classes -----
|
|
12641
|
-
type PerfectionistSortClasses =
|
|
12685
|
+
type PerfectionistSortClasses = {
|
|
12642
12686
|
fallbackSort?: {
|
|
12643
12687
|
type: ("alphabetical" | "natural" | "line-length" | "custom" | "unsorted" | "subgroup-order");
|
|
12644
12688
|
order?: ("asc" | "desc");
|
|
@@ -12755,6 +12799,16 @@ type PerfectionistSortClasses = [] | [{
|
|
|
12755
12799
|
order?: ("asc" | "desc");
|
|
12756
12800
|
})[];
|
|
12757
12801
|
newlinesBetween?: ("ignore" | number);
|
|
12802
|
+
useConfigurationIf?: {
|
|
12803
|
+
allNamesMatchPattern?: (({
|
|
12804
|
+
pattern: string;
|
|
12805
|
+
flags?: string;
|
|
12806
|
+
} | string)[] | ({
|
|
12807
|
+
pattern: string;
|
|
12808
|
+
flags?: string;
|
|
12809
|
+
} | string));
|
|
12810
|
+
matchesAstSelector?: string;
|
|
12811
|
+
};
|
|
12758
12812
|
useExperimentalDependencyDetection?: boolean;
|
|
12759
12813
|
ignoreCallbackDependenciesPatterns?: (({
|
|
12760
12814
|
pattern: string;
|
|
@@ -12786,7 +12840,7 @@ type PerfectionistSortClasses = [] | [{
|
|
|
12786
12840
|
} | string)));
|
|
12787
12841
|
});
|
|
12788
12842
|
partitionByNewLine?: boolean;
|
|
12789
|
-
}]; // ----- perfectionist/sort-decorators -----
|
|
12843
|
+
}[]; // ----- perfectionist/sort-decorators -----
|
|
12790
12844
|
type PerfectionistSortDecorators = {
|
|
12791
12845
|
fallbackSort?: {
|
|
12792
12846
|
type: ("alphabetical" | "natural" | "line-length" | "custom" | "unsorted" | "subgroup-order");
|
|
@@ -12885,7 +12939,7 @@ type PerfectionistSortDecorators = {
|
|
|
12885
12939
|
});
|
|
12886
12940
|
partitionByNewLine?: boolean;
|
|
12887
12941
|
}[]; // ----- perfectionist/sort-enums -----
|
|
12888
|
-
type PerfectionistSortEnums =
|
|
12942
|
+
type PerfectionistSortEnums = {
|
|
12889
12943
|
fallbackSort?: {
|
|
12890
12944
|
type: ("alphabetical" | "natural" | "line-length" | "custom" | "unsorted" | "subgroup-order");
|
|
12891
12945
|
order?: ("asc" | "desc");
|
|
@@ -12975,6 +13029,16 @@ type PerfectionistSortEnums = [] | [{
|
|
|
12975
13029
|
order?: ("asc" | "desc");
|
|
12976
13030
|
})[];
|
|
12977
13031
|
newlinesBetween?: ("ignore" | number);
|
|
13032
|
+
useConfigurationIf?: {
|
|
13033
|
+
allNamesMatchPattern?: (({
|
|
13034
|
+
pattern: string;
|
|
13035
|
+
flags?: string;
|
|
13036
|
+
} | string)[] | ({
|
|
13037
|
+
pattern: string;
|
|
13038
|
+
flags?: string;
|
|
13039
|
+
} | string));
|
|
13040
|
+
matchesAstSelector?: string;
|
|
13041
|
+
};
|
|
12978
13042
|
sortByValue?: ("always" | "ifNumericEnum" | "never");
|
|
12979
13043
|
useExperimentalDependencyDetection?: boolean;
|
|
12980
13044
|
partitionByComment?: (boolean | (({
|
|
@@ -13000,7 +13064,7 @@ type PerfectionistSortEnums = [] | [{
|
|
|
13000
13064
|
} | string)));
|
|
13001
13065
|
});
|
|
13002
13066
|
partitionByNewLine?: boolean;
|
|
13003
|
-
}]; // ----- perfectionist/sort-export-attributes -----
|
|
13067
|
+
}[]; // ----- perfectionist/sort-export-attributes -----
|
|
13004
13068
|
type PerfectionistSortExportAttributes = {
|
|
13005
13069
|
fallbackSort?: {
|
|
13006
13070
|
type: ("alphabetical" | "natural" | "line-length" | "custom" | "unsorted" | "subgroup-order");
|
|
@@ -13070,6 +13134,16 @@ type PerfectionistSortExportAttributes = {
|
|
|
13070
13134
|
order?: ("asc" | "desc");
|
|
13071
13135
|
})[];
|
|
13072
13136
|
newlinesBetween?: ("ignore" | number);
|
|
13137
|
+
useConfigurationIf?: {
|
|
13138
|
+
allNamesMatchPattern?: (({
|
|
13139
|
+
pattern: string;
|
|
13140
|
+
flags?: string;
|
|
13141
|
+
} | string)[] | ({
|
|
13142
|
+
pattern: string;
|
|
13143
|
+
flags?: string;
|
|
13144
|
+
} | string));
|
|
13145
|
+
matchesAstSelector?: string;
|
|
13146
|
+
};
|
|
13073
13147
|
partitionByComment?: (boolean | (({
|
|
13074
13148
|
pattern: string;
|
|
13075
13149
|
flags?: string;
|
|
@@ -13262,6 +13336,16 @@ type PerfectionistSortHeritageClauses = {
|
|
|
13262
13336
|
order?: ("asc" | "desc");
|
|
13263
13337
|
})[];
|
|
13264
13338
|
newlinesBetween?: ("ignore" | number);
|
|
13339
|
+
useConfigurationIf?: {
|
|
13340
|
+
allNamesMatchPattern?: (({
|
|
13341
|
+
pattern: string;
|
|
13342
|
+
flags?: string;
|
|
13343
|
+
} | string)[] | ({
|
|
13344
|
+
pattern: string;
|
|
13345
|
+
flags?: string;
|
|
13346
|
+
} | string));
|
|
13347
|
+
matchesAstSelector?: string;
|
|
13348
|
+
};
|
|
13265
13349
|
partitionByNewLine?: boolean;
|
|
13266
13350
|
partitionByComment?: (boolean | (({
|
|
13267
13351
|
pattern: string;
|
|
@@ -13355,6 +13439,16 @@ type PerfectionistSortImportAttributes = {
|
|
|
13355
13439
|
order?: ("asc" | "desc");
|
|
13356
13440
|
})[];
|
|
13357
13441
|
newlinesBetween?: ("ignore" | number);
|
|
13442
|
+
useConfigurationIf?: {
|
|
13443
|
+
allNamesMatchPattern?: (({
|
|
13444
|
+
pattern: string;
|
|
13445
|
+
flags?: string;
|
|
13446
|
+
} | string)[] | ({
|
|
13447
|
+
pattern: string;
|
|
13448
|
+
flags?: string;
|
|
13449
|
+
} | string));
|
|
13450
|
+
matchesAstSelector?: string;
|
|
13451
|
+
};
|
|
13358
13452
|
partitionByComment?: (boolean | (({
|
|
13359
13453
|
pattern: string;
|
|
13360
13454
|
flags?: string;
|
|
@@ -13623,6 +13717,7 @@ type PerfectionistSortInterfaces = {
|
|
|
13623
13717
|
pattern: string;
|
|
13624
13718
|
flags?: string;
|
|
13625
13719
|
} | string));
|
|
13720
|
+
matchesAstSelector?: string;
|
|
13626
13721
|
declarationMatchesPattern?: (({
|
|
13627
13722
|
scope?: ("shallow" | "deep");
|
|
13628
13723
|
pattern: string;
|
|
@@ -13729,6 +13824,16 @@ type PerfectionistSortIntersectionTypes = {
|
|
|
13729
13824
|
order?: ("asc" | "desc");
|
|
13730
13825
|
})[];
|
|
13731
13826
|
newlinesBetween?: ("ignore" | number);
|
|
13827
|
+
useConfigurationIf?: {
|
|
13828
|
+
allNamesMatchPattern?: (({
|
|
13829
|
+
pattern: string;
|
|
13830
|
+
flags?: string;
|
|
13831
|
+
} | string)[] | ({
|
|
13832
|
+
pattern: string;
|
|
13833
|
+
flags?: string;
|
|
13834
|
+
} | string));
|
|
13835
|
+
matchesAstSelector?: string;
|
|
13836
|
+
};
|
|
13732
13837
|
partitionByComment?: (boolean | (({
|
|
13733
13838
|
pattern: string;
|
|
13734
13839
|
flags?: string;
|
|
@@ -13857,6 +13962,7 @@ type PerfectionistSortJsxProps = {
|
|
|
13857
13962
|
pattern: string;
|
|
13858
13963
|
flags?: string;
|
|
13859
13964
|
} | string));
|
|
13965
|
+
matchesAstSelector?: string;
|
|
13860
13966
|
tagMatchesPattern?: (({
|
|
13861
13967
|
pattern: string;
|
|
13862
13968
|
flags?: string;
|
|
@@ -13944,6 +14050,7 @@ type PerfectionistSortMaps = {
|
|
|
13944
14050
|
pattern: string;
|
|
13945
14051
|
flags?: string;
|
|
13946
14052
|
} | string));
|
|
14053
|
+
matchesAstSelector?: string;
|
|
13947
14054
|
};
|
|
13948
14055
|
partitionByComment?: (boolean | (({
|
|
13949
14056
|
pattern: string;
|
|
@@ -14165,6 +14272,16 @@ type PerfectionistSortNamedExports = {
|
|
|
14165
14272
|
order?: ("asc" | "desc");
|
|
14166
14273
|
})[];
|
|
14167
14274
|
newlinesBetween?: ("ignore" | number);
|
|
14275
|
+
useConfigurationIf?: {
|
|
14276
|
+
allNamesMatchPattern?: (({
|
|
14277
|
+
pattern: string;
|
|
14278
|
+
flags?: string;
|
|
14279
|
+
} | string)[] | ({
|
|
14280
|
+
pattern: string;
|
|
14281
|
+
flags?: string;
|
|
14282
|
+
} | string));
|
|
14283
|
+
matchesAstSelector?: string;
|
|
14284
|
+
};
|
|
14168
14285
|
ignoreAlias?: boolean;
|
|
14169
14286
|
partitionByComment?: (boolean | (({
|
|
14170
14287
|
pattern: string;
|
|
@@ -14265,6 +14382,16 @@ type PerfectionistSortNamedImports = {
|
|
|
14265
14382
|
order?: ("asc" | "desc");
|
|
14266
14383
|
})[];
|
|
14267
14384
|
newlinesBetween?: ("ignore" | number);
|
|
14385
|
+
useConfigurationIf?: {
|
|
14386
|
+
allNamesMatchPattern?: (({
|
|
14387
|
+
pattern: string;
|
|
14388
|
+
flags?: string;
|
|
14389
|
+
} | string)[] | ({
|
|
14390
|
+
pattern: string;
|
|
14391
|
+
flags?: string;
|
|
14392
|
+
} | string));
|
|
14393
|
+
matchesAstSelector?: string;
|
|
14394
|
+
};
|
|
14268
14395
|
ignoreAlias?: boolean;
|
|
14269
14396
|
partitionByComment?: (boolean | (({
|
|
14270
14397
|
pattern: string;
|
|
@@ -14412,6 +14539,7 @@ type PerfectionistSortObjectTypes = {
|
|
|
14412
14539
|
pattern: string;
|
|
14413
14540
|
flags?: string;
|
|
14414
14541
|
} | string));
|
|
14542
|
+
matchesAstSelector?: string;
|
|
14415
14543
|
declarationMatchesPattern?: (({
|
|
14416
14544
|
scope?: ("shallow" | "deep");
|
|
14417
14545
|
pattern: string;
|
|
@@ -14578,6 +14706,7 @@ type PerfectionistSortObjects = {
|
|
|
14578
14706
|
pattern: string;
|
|
14579
14707
|
flags?: string;
|
|
14580
14708
|
} | string));
|
|
14709
|
+
matchesAstSelector?: string;
|
|
14581
14710
|
declarationMatchesPattern?: (({
|
|
14582
14711
|
scope?: ("shallow" | "deep");
|
|
14583
14712
|
pattern: string;
|
|
@@ -14588,6 +14717,7 @@ type PerfectionistSortObjects = {
|
|
|
14588
14717
|
flags?: string;
|
|
14589
14718
|
} | string));
|
|
14590
14719
|
};
|
|
14720
|
+
partitionByComputedKey?: boolean;
|
|
14591
14721
|
styledComponents?: boolean;
|
|
14592
14722
|
useExperimentalDependencyDetection?: boolean;
|
|
14593
14723
|
partitionByComment?: (boolean | (({
|
|
@@ -14694,6 +14824,7 @@ type PerfectionistSortSets = {
|
|
|
14694
14824
|
pattern: string;
|
|
14695
14825
|
flags?: string;
|
|
14696
14826
|
} | string));
|
|
14827
|
+
matchesAstSelector?: string;
|
|
14697
14828
|
};
|
|
14698
14829
|
partitionByComment?: (boolean | (({
|
|
14699
14830
|
pattern: string;
|
|
@@ -14803,6 +14934,16 @@ type PerfectionistSortUnionTypes = {
|
|
|
14803
14934
|
order?: ("asc" | "desc");
|
|
14804
14935
|
})[];
|
|
14805
14936
|
newlinesBetween?: ("ignore" | number);
|
|
14937
|
+
useConfigurationIf?: {
|
|
14938
|
+
allNamesMatchPattern?: (({
|
|
14939
|
+
pattern: string;
|
|
14940
|
+
flags?: string;
|
|
14941
|
+
} | string)[] | ({
|
|
14942
|
+
pattern: string;
|
|
14943
|
+
flags?: string;
|
|
14944
|
+
} | string));
|
|
14945
|
+
matchesAstSelector?: string;
|
|
14946
|
+
};
|
|
14806
14947
|
partitionByComment?: (boolean | (({
|
|
14807
14948
|
pattern: string;
|
|
14808
14949
|
flags?: string;
|
|
@@ -14827,7 +14968,7 @@ type PerfectionistSortUnionTypes = {
|
|
|
14827
14968
|
});
|
|
14828
14969
|
partitionByNewLine?: boolean;
|
|
14829
14970
|
}[]; // ----- perfectionist/sort-variable-declarations -----
|
|
14830
|
-
type PerfectionistSortVariableDeclarations =
|
|
14971
|
+
type PerfectionistSortVariableDeclarations = {
|
|
14831
14972
|
fallbackSort?: {
|
|
14832
14973
|
type: ("alphabetical" | "natural" | "line-length" | "custom" | "unsorted" | "subgroup-order");
|
|
14833
14974
|
order?: ("asc" | "desc");
|
|
@@ -14899,6 +15040,16 @@ type PerfectionistSortVariableDeclarations = [] | [{
|
|
|
14899
15040
|
order?: ("asc" | "desc");
|
|
14900
15041
|
})[];
|
|
14901
15042
|
newlinesBetween?: ("ignore" | number);
|
|
15043
|
+
useConfigurationIf?: {
|
|
15044
|
+
allNamesMatchPattern?: (({
|
|
15045
|
+
pattern: string;
|
|
15046
|
+
flags?: string;
|
|
15047
|
+
} | string)[] | ({
|
|
15048
|
+
pattern: string;
|
|
15049
|
+
flags?: string;
|
|
15050
|
+
} | string));
|
|
15051
|
+
matchesAstSelector?: string;
|
|
15052
|
+
};
|
|
14902
15053
|
useExperimentalDependencyDetection?: boolean;
|
|
14903
15054
|
partitionByComment?: (boolean | (({
|
|
14904
15055
|
pattern: string;
|
|
@@ -14923,7 +15074,7 @@ type PerfectionistSortVariableDeclarations = [] | [{
|
|
|
14923
15074
|
} | string)));
|
|
14924
15075
|
});
|
|
14925
15076
|
partitionByNewLine?: boolean;
|
|
14926
|
-
}]; // ----- pinia/prefer-use-store-naming-convention -----
|
|
15077
|
+
}[]; // ----- pinia/prefer-use-store-naming-convention -----
|
|
14927
15078
|
type PiniaPreferUseStoreNamingConvention = [] | [{
|
|
14928
15079
|
checkStoreNameMismatch?: boolean;
|
|
14929
15080
|
storeSuffix?: string;
|
|
@@ -15260,6 +15411,13 @@ type SvelteIndent = [] | [{
|
|
|
15260
15411
|
type SvelteMaxAttributesPerLine = [] | [{
|
|
15261
15412
|
multiline?: number;
|
|
15262
15413
|
singleline?: number;
|
|
15414
|
+
}]; // ----- svelte/max-lines-per-block -----
|
|
15415
|
+
type SvelteMaxLinesPerBlock = [] | [{
|
|
15416
|
+
script?: number;
|
|
15417
|
+
template?: number;
|
|
15418
|
+
style?: number;
|
|
15419
|
+
skipBlankLines?: boolean;
|
|
15420
|
+
skipComments?: boolean;
|
|
15263
15421
|
}]; // ----- svelte/mustache-spacing -----
|
|
15264
15422
|
type SvelteMustacheSpacing = [] | [{
|
|
15265
15423
|
textExpressions?: ("never" | "always");
|
|
@@ -15989,6 +16147,7 @@ type UnicornEscapeCase = [] | [("uppercase" | "lowercase")]; // ----- unicorn/ex
|
|
|
15989
16147
|
type UnicornExpiringTodoComments = [] | [{
|
|
15990
16148
|
terms?: string[];
|
|
15991
16149
|
ignore?: unknown[];
|
|
16150
|
+
ignoreDates?: boolean;
|
|
15992
16151
|
ignoreDatesOnPullRequests?: boolean;
|
|
15993
16152
|
allowWarningComments?: boolean;
|
|
15994
16153
|
date?: string;
|
|
@@ -16145,6 +16304,9 @@ type _UnicornPreventAbbreviationsReplacements = (false | _UnicornPreventAbbrevia
|
|
|
16145
16304
|
interface _UnicornPreventAbbreviations_Abbreviations {
|
|
16146
16305
|
[k: string]: _UnicornPreventAbbreviationsReplacements | undefined;
|
|
16147
16306
|
}
|
|
16307
|
+
interface _UnicornPreventAbbreviations_BooleanObject {
|
|
16308
|
+
[k: string]: boolean | undefined;
|
|
16309
|
+
}
|
|
16148
16310
|
interface _UnicornPreventAbbreviations_BooleanObject {
|
|
16149
16311
|
[k: string]: boolean | undefined;
|
|
16150
16312
|
} // ----- unicorn/relative-url-style -----
|
|
@@ -16259,6 +16421,9 @@ type VitestRequireMockTypeParameters = [] | [{
|
|
|
16259
16421
|
}]; // ----- vitest/require-top-level-describe -----
|
|
16260
16422
|
type VitestRequireTopLevelDescribe = [] | [{
|
|
16261
16423
|
maxNumberOfTopLevelDescribes?: number;
|
|
16424
|
+
}]; // ----- vitest/unbound-method -----
|
|
16425
|
+
type VitestUnboundMethod = [] | [{
|
|
16426
|
+
ignoreStatic?: boolean;
|
|
16262
16427
|
}]; // ----- vitest/valid-expect -----
|
|
16263
16428
|
type VitestValidExpect = [] | [{
|
|
16264
16429
|
alwaysAwait?: boolean;
|
|
@@ -17787,19 +17952,19 @@ declare function isInGitHooksOrRunBySpecifyPackages(): boolean;
|
|
|
17787
17952
|
*/
|
|
17788
17953
|
declare const PERFECTIONIST: Readonly<{
|
|
17789
17954
|
partialRuleOptions: {
|
|
17790
|
-
readonly newlinesBetween:
|
|
17955
|
+
readonly newlinesBetween: 'ignore';
|
|
17791
17956
|
readonly partitionByComment: string[];
|
|
17792
17957
|
};
|
|
17793
17958
|
pluginSettings: {
|
|
17794
17959
|
readonly fallbackSort: {
|
|
17795
|
-
readonly order:
|
|
17796
|
-
readonly type:
|
|
17960
|
+
readonly order: 'asc';
|
|
17961
|
+
readonly type: 'alphabetical';
|
|
17797
17962
|
};
|
|
17798
17963
|
readonly ignoreCase: true;
|
|
17799
|
-
readonly order:
|
|
17964
|
+
readonly order: 'asc';
|
|
17800
17965
|
readonly partitionByNewLine: false;
|
|
17801
|
-
readonly specialCharacters:
|
|
17802
|
-
readonly type:
|
|
17966
|
+
readonly specialCharacters: 'keep';
|
|
17967
|
+
readonly type: 'alphabetical';
|
|
17803
17968
|
};
|
|
17804
17969
|
sortClassesGroups: (string | NonEmptyArray<string>)[];
|
|
17805
17970
|
sortExportAttributesGroups: string[];
|