@jsse/eslint-config 0.1.20 → 0.1.22
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/LICENSE +21 -21
- package/dist/cli.cjs +1 -1
- package/dist/cli.js +1 -1
- package/dist/index.cjs +256 -170
- package/dist/index.d.cts +530 -330
- package/dist/index.d.ts +530 -330
- package/dist/index.js +257 -171
- package/package.json +27 -28
package/dist/index.d.ts
CHANGED
|
@@ -4329,42 +4329,42 @@ interface IgnoresRuleOptions {}
|
|
|
4329
4329
|
interface ImportsRuleOptions {
|
|
4330
4330
|
/**
|
|
4331
4331
|
* Enforce or ban the use of inline type-only markers for named imports.
|
|
4332
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4332
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/consistent-type-specifier-style.md
|
|
4333
4333
|
*/
|
|
4334
4334
|
"import/consistent-type-specifier-style"?: Linter.RuleEntry<ImportConsistentTypeSpecifierStyle$1>;
|
|
4335
4335
|
/**
|
|
4336
4336
|
* Ensure a default export is present, given a default import.
|
|
4337
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4337
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/default.md
|
|
4338
4338
|
*/
|
|
4339
4339
|
"import/default"?: Linter.RuleEntry<[]>;
|
|
4340
4340
|
/**
|
|
4341
4341
|
* Enforce a leading comment with the webpackChunkName for dynamic imports.
|
|
4342
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4342
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/dynamic-import-chunkname.md
|
|
4343
4343
|
*/
|
|
4344
4344
|
"import/dynamic-import-chunkname"?: Linter.RuleEntry<ImportDynamicImportChunkname$1>;
|
|
4345
4345
|
/**
|
|
4346
4346
|
* Forbid any invalid exports, i.e. re-export of the same name.
|
|
4347
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4347
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/export.md
|
|
4348
4348
|
*/
|
|
4349
4349
|
"import/export"?: Linter.RuleEntry<[]>;
|
|
4350
4350
|
/**
|
|
4351
4351
|
* Ensure all exports appear after other statements.
|
|
4352
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4352
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/exports-last.md
|
|
4353
4353
|
*/
|
|
4354
4354
|
"import/exports-last"?: Linter.RuleEntry<[]>;
|
|
4355
4355
|
/**
|
|
4356
4356
|
* Ensure consistent use of file extension within the import path.
|
|
4357
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4357
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/extensions.md
|
|
4358
4358
|
*/
|
|
4359
4359
|
"import/extensions"?: Linter.RuleEntry<ImportExtensions$1>;
|
|
4360
4360
|
/**
|
|
4361
4361
|
* Ensure all imports appear before other statements.
|
|
4362
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4362
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/first.md
|
|
4363
4363
|
*/
|
|
4364
4364
|
"import/first"?: Linter.RuleEntry<ImportFirst$1>;
|
|
4365
4365
|
/**
|
|
4366
4366
|
* Prefer named exports to be grouped together in a single export declaration.
|
|
4367
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4367
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/group-exports.md
|
|
4368
4368
|
*/
|
|
4369
4369
|
"import/group-exports"?: Linter.RuleEntry<[]>;
|
|
4370
4370
|
/**
|
|
@@ -4375,182 +4375,182 @@ interface ImportsRuleOptions {
|
|
|
4375
4375
|
"import/imports-first"?: Linter.RuleEntry<ImportImportsFirst$1>;
|
|
4376
4376
|
/**
|
|
4377
4377
|
* Enforce the maximum number of dependencies a module can have.
|
|
4378
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4378
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/max-dependencies.md
|
|
4379
4379
|
*/
|
|
4380
4380
|
"import/max-dependencies"?: Linter.RuleEntry<ImportMaxDependencies$1>;
|
|
4381
4381
|
/**
|
|
4382
4382
|
* Ensure named imports correspond to a named export in the remote file.
|
|
4383
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4383
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/named.md
|
|
4384
4384
|
*/
|
|
4385
4385
|
"import/named"?: Linter.RuleEntry<ImportNamed$1>;
|
|
4386
4386
|
/**
|
|
4387
4387
|
* Ensure imported namespaces contain dereferenced properties as they are dereferenced.
|
|
4388
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4388
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/namespace.md
|
|
4389
4389
|
*/
|
|
4390
4390
|
"import/namespace"?: Linter.RuleEntry<ImportNamespace$1>;
|
|
4391
4391
|
/**
|
|
4392
4392
|
* Enforce a newline after import statements.
|
|
4393
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4393
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/newline-after-import.md
|
|
4394
4394
|
*/
|
|
4395
4395
|
"import/newline-after-import"?: Linter.RuleEntry<ImportNewlineAfterImport$1>;
|
|
4396
4396
|
/**
|
|
4397
4397
|
* Forbid import of modules using absolute paths.
|
|
4398
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4398
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-absolute-path.md
|
|
4399
4399
|
*/
|
|
4400
4400
|
"import/no-absolute-path"?: Linter.RuleEntry<ImportNoAbsolutePath$1>;
|
|
4401
4401
|
/**
|
|
4402
4402
|
* Forbid AMD `require` and `define` calls.
|
|
4403
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4403
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-amd.md
|
|
4404
4404
|
*/
|
|
4405
4405
|
"import/no-amd"?: Linter.RuleEntry<[]>;
|
|
4406
4406
|
/**
|
|
4407
4407
|
* Forbid anonymous values as default exports.
|
|
4408
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4408
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-anonymous-default-export.md
|
|
4409
4409
|
*/
|
|
4410
4410
|
"import/no-anonymous-default-export"?: Linter.RuleEntry<ImportNoAnonymousDefaultExport$1>;
|
|
4411
4411
|
/**
|
|
4412
4412
|
* Forbid CommonJS `require` calls and `module.exports` or `exports.*`.
|
|
4413
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4413
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-commonjs.md
|
|
4414
4414
|
*/
|
|
4415
4415
|
"import/no-commonjs"?: Linter.RuleEntry<ImportNoCommonjs$1>;
|
|
4416
4416
|
/**
|
|
4417
4417
|
* Forbid a module from importing a module with a dependency path back to itself.
|
|
4418
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4418
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-cycle.md
|
|
4419
4419
|
*/
|
|
4420
4420
|
"import/no-cycle"?: Linter.RuleEntry<ImportNoCycle$1>;
|
|
4421
4421
|
/**
|
|
4422
4422
|
* Forbid default exports.
|
|
4423
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4423
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-default-export.md
|
|
4424
4424
|
*/
|
|
4425
4425
|
"import/no-default-export"?: Linter.RuleEntry<[]>;
|
|
4426
4426
|
/**
|
|
4427
4427
|
* Forbid imported names marked with `@deprecated` documentation tag.
|
|
4428
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4428
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-deprecated.md
|
|
4429
4429
|
*/
|
|
4430
4430
|
"import/no-deprecated"?: Linter.RuleEntry<[]>;
|
|
4431
4431
|
/**
|
|
4432
4432
|
* Forbid repeated import of the same module in multiple places.
|
|
4433
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4433
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-duplicates.md
|
|
4434
4434
|
*/
|
|
4435
4435
|
"import/no-duplicates"?: Linter.RuleEntry<ImportNoDuplicates$1>;
|
|
4436
4436
|
/**
|
|
4437
4437
|
* Forbid `require()` calls with expressions.
|
|
4438
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4438
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-dynamic-require.md
|
|
4439
4439
|
*/
|
|
4440
4440
|
"import/no-dynamic-require"?: Linter.RuleEntry<ImportNoDynamicRequire$1>;
|
|
4441
4441
|
/**
|
|
4442
4442
|
* Forbid empty named import blocks.
|
|
4443
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4443
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-empty-named-blocks.md
|
|
4444
4444
|
*/
|
|
4445
4445
|
"import/no-empty-named-blocks"?: Linter.RuleEntry<[]>;
|
|
4446
4446
|
/**
|
|
4447
4447
|
* Forbid the use of extraneous packages.
|
|
4448
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4448
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-extraneous-dependencies.md
|
|
4449
4449
|
*/
|
|
4450
4450
|
"import/no-extraneous-dependencies"?: Linter.RuleEntry<ImportNoExtraneousDependencies$1>;
|
|
4451
4451
|
/**
|
|
4452
4452
|
* Forbid import statements with CommonJS module.exports.
|
|
4453
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4453
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-import-module-exports.md
|
|
4454
4454
|
*/
|
|
4455
4455
|
"import/no-import-module-exports"?: Linter.RuleEntry<ImportNoImportModuleExports$1>;
|
|
4456
4456
|
/**
|
|
4457
4457
|
* Forbid importing the submodules of other modules.
|
|
4458
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4458
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-internal-modules.md
|
|
4459
4459
|
*/
|
|
4460
4460
|
"import/no-internal-modules"?: Linter.RuleEntry<ImportNoInternalModules$1>;
|
|
4461
4461
|
/**
|
|
4462
4462
|
* Forbid the use of mutable exports with `var` or `let`.
|
|
4463
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4463
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-mutable-exports.md
|
|
4464
4464
|
*/
|
|
4465
4465
|
"import/no-mutable-exports"?: Linter.RuleEntry<[]>;
|
|
4466
4466
|
/**
|
|
4467
4467
|
* Forbid use of exported name as identifier of default export.
|
|
4468
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4468
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-as-default.md
|
|
4469
4469
|
*/
|
|
4470
4470
|
"import/no-named-as-default"?: Linter.RuleEntry<[]>;
|
|
4471
4471
|
/**
|
|
4472
4472
|
* Forbid use of exported name as property of default export.
|
|
4473
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4473
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-as-default-member.md
|
|
4474
4474
|
*/
|
|
4475
4475
|
"import/no-named-as-default-member"?: Linter.RuleEntry<[]>;
|
|
4476
4476
|
/**
|
|
4477
4477
|
* Forbid named default exports.
|
|
4478
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4478
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-default.md
|
|
4479
4479
|
*/
|
|
4480
4480
|
"import/no-named-default"?: Linter.RuleEntry<[]>;
|
|
4481
4481
|
/**
|
|
4482
4482
|
* Forbid named exports.
|
|
4483
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4483
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-export.md
|
|
4484
4484
|
*/
|
|
4485
4485
|
"import/no-named-export"?: Linter.RuleEntry<[]>;
|
|
4486
4486
|
/**
|
|
4487
4487
|
* Forbid namespace (a.k.a. "wildcard" `*`) imports.
|
|
4488
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4488
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-namespace.md
|
|
4489
4489
|
*/
|
|
4490
4490
|
"import/no-namespace"?: Linter.RuleEntry<ImportNoNamespace$1>;
|
|
4491
4491
|
/**
|
|
4492
4492
|
* Forbid Node.js builtin modules.
|
|
4493
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4493
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-nodejs-modules.md
|
|
4494
4494
|
*/
|
|
4495
4495
|
"import/no-nodejs-modules"?: Linter.RuleEntry<ImportNoNodejsModules$1>;
|
|
4496
4496
|
/**
|
|
4497
4497
|
* Forbid importing packages through relative paths.
|
|
4498
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4498
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-relative-packages.md
|
|
4499
4499
|
*/
|
|
4500
4500
|
"import/no-relative-packages"?: Linter.RuleEntry<ImportNoRelativePackages$1>;
|
|
4501
4501
|
/**
|
|
4502
4502
|
* Forbid importing modules from parent directories.
|
|
4503
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4503
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-relative-parent-imports.md
|
|
4504
4504
|
*/
|
|
4505
4505
|
"import/no-relative-parent-imports"?: Linter.RuleEntry<ImportNoRelativeParentImports$1>;
|
|
4506
4506
|
/**
|
|
4507
4507
|
* Enforce which files can be imported in a given folder.
|
|
4508
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4508
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-restricted-paths.md
|
|
4509
4509
|
*/
|
|
4510
4510
|
"import/no-restricted-paths"?: Linter.RuleEntry<ImportNoRestrictedPaths$1>;
|
|
4511
4511
|
/**
|
|
4512
4512
|
* Forbid a module from importing itself.
|
|
4513
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4513
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-self-import.md
|
|
4514
4514
|
*/
|
|
4515
4515
|
"import/no-self-import"?: Linter.RuleEntry<[]>;
|
|
4516
4516
|
/**
|
|
4517
4517
|
* Forbid unassigned imports.
|
|
4518
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4518
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unassigned-import.md
|
|
4519
4519
|
*/
|
|
4520
4520
|
"import/no-unassigned-import"?: Linter.RuleEntry<ImportNoUnassignedImport$1>;
|
|
4521
4521
|
/**
|
|
4522
4522
|
* Ensure imports point to a file/module that can be resolved.
|
|
4523
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4523
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unresolved.md
|
|
4524
4524
|
*/
|
|
4525
4525
|
"import/no-unresolved"?: Linter.RuleEntry<ImportNoUnresolved$1>;
|
|
4526
4526
|
/**
|
|
4527
4527
|
* Forbid modules without exports, or exports without matching import in another module.
|
|
4528
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4528
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unused-modules.md
|
|
4529
4529
|
*/
|
|
4530
4530
|
"import/no-unused-modules"?: Linter.RuleEntry<ImportNoUnusedModules$1>;
|
|
4531
4531
|
/**
|
|
4532
4532
|
* Forbid unnecessary path segments in import and require statements.
|
|
4533
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4533
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-useless-path-segments.md
|
|
4534
4534
|
*/
|
|
4535
4535
|
"import/no-useless-path-segments"?: Linter.RuleEntry<ImportNoUselessPathSegments$1>;
|
|
4536
4536
|
/**
|
|
4537
4537
|
* Forbid webpack loader syntax in imports.
|
|
4538
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4538
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-webpack-loader-syntax.md
|
|
4539
4539
|
*/
|
|
4540
4540
|
"import/no-webpack-loader-syntax"?: Linter.RuleEntry<[]>;
|
|
4541
4541
|
/**
|
|
4542
4542
|
* Enforce a convention in module import order.
|
|
4543
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4543
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/order.md
|
|
4544
4544
|
*/
|
|
4545
4545
|
"import/order"?: Linter.RuleEntry<ImportOrder$1>;
|
|
4546
4546
|
/**
|
|
4547
4547
|
* Prefer a default export if module exports a single name or multiple names.
|
|
4548
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4548
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/prefer-default-export.md
|
|
4549
4549
|
*/
|
|
4550
4550
|
"import/prefer-default-export"?: Linter.RuleEntry<ImportPreferDefaultExport$1>;
|
|
4551
4551
|
/**
|
|
4552
4552
|
* Forbid potentially ambiguous parse goal (`script` vs. `module`).
|
|
4553
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
4553
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/unambiguous.md
|
|
4554
4554
|
*/
|
|
4555
4555
|
"import/unambiguous"?: Linter.RuleEntry<[]>;
|
|
4556
4556
|
}
|
|
@@ -5065,6 +5065,11 @@ interface JsdocRuleOptions {
|
|
|
5065
5065
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-tag-names.md#repos-sticky-header
|
|
5066
5066
|
*/
|
|
5067
5067
|
"jsdoc/check-tag-names"?: Linter.RuleEntry<JsdocCheckTagNames>;
|
|
5068
|
+
/**
|
|
5069
|
+
* Checks that any `@template` names are actually used in the connected `@typedef` or type alias.
|
|
5070
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-template.md#repos-sticky-header
|
|
5071
|
+
*/
|
|
5072
|
+
"jsdoc/check-template-names"?: Linter.RuleEntry<[]>;
|
|
5068
5073
|
/**
|
|
5069
5074
|
* Reports invalid types.
|
|
5070
5075
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-types.md#repos-sticky-header
|
|
@@ -8256,6 +8261,9 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
8256
8261
|
| "navigator.platform"
|
|
8257
8262
|
| "navigator.userAgent"
|
|
8258
8263
|
| "structuredClone"
|
|
8264
|
+
| "localStorage"
|
|
8265
|
+
| "sessionStorage"
|
|
8266
|
+
| "Storage"
|
|
8259
8267
|
| "Blob"
|
|
8260
8268
|
| "new Buffer()"
|
|
8261
8269
|
| "Buffer"
|
|
@@ -8339,6 +8347,10 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
8339
8347
|
| "process.execArgv"
|
|
8340
8348
|
| "process.execPath"
|
|
8341
8349
|
| "process.exitCode"
|
|
8350
|
+
| "process.finalization.register"
|
|
8351
|
+
| "process.finalization.registerBeforeExit"
|
|
8352
|
+
| "process.finalization.unregister"
|
|
8353
|
+
| "process.getBuiltinModule"
|
|
8342
8354
|
| "process.mainModule"
|
|
8343
8355
|
| "process.noDeprecation"
|
|
8344
8356
|
| "process.permission"
|
|
@@ -9058,6 +9070,7 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9058
9070
|
| "path.posix.dirname"
|
|
9059
9071
|
| "path.posix.extname"
|
|
9060
9072
|
| "path.posix.format"
|
|
9073
|
+
| "path.posix.matchesGlob"
|
|
9061
9074
|
| "path.posix.isAbsolute"
|
|
9062
9075
|
| "path.posix.join"
|
|
9063
9076
|
| "path.posix.normalize"
|
|
@@ -9072,6 +9085,7 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9072
9085
|
| "path.win32.dirname"
|
|
9073
9086
|
| "path.win32.extname"
|
|
9074
9087
|
| "path.win32.format"
|
|
9088
|
+
| "path.win32.matchesGlob"
|
|
9075
9089
|
| "path.win32.isAbsolute"
|
|
9076
9090
|
| "path.win32.join"
|
|
9077
9091
|
| "path.win32.normalize"
|
|
@@ -9085,6 +9099,7 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9085
9099
|
| "path.dirname"
|
|
9086
9100
|
| "path.extname"
|
|
9087
9101
|
| "path.format"
|
|
9102
|
+
| "path.matchesGlob"
|
|
9088
9103
|
| "path.isAbsolute"
|
|
9089
9104
|
| "path.join"
|
|
9090
9105
|
| "path.normalize"
|
|
@@ -9099,6 +9114,7 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9099
9114
|
| "path/posix.dirname"
|
|
9100
9115
|
| "path/posix.extname"
|
|
9101
9116
|
| "path/posix.format"
|
|
9117
|
+
| "path/posix.matchesGlob"
|
|
9102
9118
|
| "path/posix.isAbsolute"
|
|
9103
9119
|
| "path/posix.join"
|
|
9104
9120
|
| "path/posix.normalize"
|
|
@@ -9113,6 +9129,7 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9113
9129
|
| "path/win32.dirname"
|
|
9114
9130
|
| "path/win32.extname"
|
|
9115
9131
|
| "path/win32.format"
|
|
9132
|
+
| "path/win32.matchesGlob"
|
|
9116
9133
|
| "path/win32.isAbsolute"
|
|
9117
9134
|
| "path/win32.join"
|
|
9118
9135
|
| "path/win32.normalize"
|
|
@@ -9250,7 +9267,11 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9250
9267
|
| "test.after"
|
|
9251
9268
|
| "test.beforeEach"
|
|
9252
9269
|
| "test.afterEach"
|
|
9270
|
+
| "test.snapshot"
|
|
9271
|
+
| "test.snapshot.setDefaultSnapshotSerializers"
|
|
9272
|
+
| "test.snapshot.setResolveSnapshotPath"
|
|
9253
9273
|
| "test.MockFunctionContext"
|
|
9274
|
+
| "test.MockModuleContext"
|
|
9254
9275
|
| "test.MockTracker"
|
|
9255
9276
|
| "test.MockTimers"
|
|
9256
9277
|
| "test.TestsStream"
|
|
@@ -9267,7 +9288,9 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9267
9288
|
| "test.test.after"
|
|
9268
9289
|
| "test.test.beforeEach"
|
|
9269
9290
|
| "test.test.afterEach"
|
|
9291
|
+
| "test.test.snapshot"
|
|
9270
9292
|
| "test.test.MockFunctionContext"
|
|
9293
|
+
| "test.test.MockModuleContext"
|
|
9271
9294
|
| "test.test.MockTracker"
|
|
9272
9295
|
| "test.test.MockTimers"
|
|
9273
9296
|
| "test.test.TestsStream"
|
|
@@ -9519,6 +9542,7 @@ type NNoUnsupportedFeaturesNodeBuiltins =
|
|
|
9519
9542
|
| "worker_threads.markAsUntransferable"
|
|
9520
9543
|
| "worker_threads.isMarkedAsUntransferable"
|
|
9521
9544
|
| "worker_threads.moveMessagePortToContext"
|
|
9545
|
+
| "worker_threads.postMessageToThread"
|
|
9522
9546
|
| "worker_threads.receiveMessageOnPort"
|
|
9523
9547
|
| "worker_threads.setEnvironmentData"
|
|
9524
9548
|
| "worker_threads.BroadcastChannel"
|
|
@@ -9626,88 +9650,98 @@ type NShebang =
|
|
|
9626
9650
|
|
|
9627
9651
|
interface PerfectionistRuleOptions {
|
|
9628
9652
|
/**
|
|
9629
|
-
*
|
|
9630
|
-
* @see https://
|
|
9653
|
+
* Enforce sorted arrays before include method.
|
|
9654
|
+
* @see https://perfectionist.dev/rules/sort-array-includes
|
|
9631
9655
|
*/
|
|
9632
9656
|
"perfectionist/sort-array-includes"?: Linter.RuleEntry<PerfectionistSortArrayIncludes>;
|
|
9633
9657
|
/**
|
|
9634
|
-
*
|
|
9635
|
-
* @see https://
|
|
9658
|
+
* Enforce sorted Astro attributes.
|
|
9659
|
+
* @see https://perfectionist.dev/rules/sort-astro-attributes
|
|
9636
9660
|
*/
|
|
9637
9661
|
"perfectionist/sort-astro-attributes"?: Linter.RuleEntry<PerfectionistSortAstroAttributes>;
|
|
9638
9662
|
/**
|
|
9639
|
-
*
|
|
9640
|
-
* @see https://
|
|
9663
|
+
* Enforce sorted classes.
|
|
9664
|
+
* @see https://perfectionist.dev/rules/sort-classes
|
|
9641
9665
|
*/
|
|
9642
9666
|
"perfectionist/sort-classes"?: Linter.RuleEntry<PerfectionistSortClasses>;
|
|
9643
9667
|
/**
|
|
9644
|
-
*
|
|
9645
|
-
* @see https://
|
|
9668
|
+
* Enforce sorted TypeScript enums.
|
|
9669
|
+
* @see https://perfectionist.dev/rules/sort-enums
|
|
9646
9670
|
*/
|
|
9647
9671
|
"perfectionist/sort-enums"?: Linter.RuleEntry<PerfectionistSortEnums>;
|
|
9648
9672
|
/**
|
|
9649
|
-
*
|
|
9650
|
-
* @see https://
|
|
9673
|
+
* Enforce sorted exports.
|
|
9674
|
+
* @see https://perfectionist.dev/rules/sort-exports
|
|
9651
9675
|
*/
|
|
9652
9676
|
"perfectionist/sort-exports"?: Linter.RuleEntry<PerfectionistSortExports>;
|
|
9653
9677
|
/**
|
|
9654
|
-
*
|
|
9655
|
-
* @see https://
|
|
9678
|
+
* Enforce sorted imports.
|
|
9679
|
+
* @see https://perfectionist.dev/rules/sort-imports
|
|
9656
9680
|
*/
|
|
9657
9681
|
"perfectionist/sort-imports"?: Linter.RuleEntry<PerfectionistSortImports>;
|
|
9658
9682
|
/**
|
|
9659
|
-
*
|
|
9660
|
-
* @see https://
|
|
9683
|
+
* Enforce sorted interface properties.
|
|
9684
|
+
* @see https://perfectionist.dev/rules/sort-interfaces
|
|
9661
9685
|
*/
|
|
9662
9686
|
"perfectionist/sort-interfaces"?: Linter.RuleEntry<PerfectionistSortInterfaces>;
|
|
9663
9687
|
/**
|
|
9664
|
-
*
|
|
9665
|
-
* @see https://
|
|
9688
|
+
* Enforce sorted intersection types.
|
|
9689
|
+
* @see https://perfectionist.dev/rules/sort-intersection-types
|
|
9666
9690
|
*/
|
|
9667
9691
|
"perfectionist/sort-intersection-types"?: Linter.RuleEntry<PerfectionistSortIntersectionTypes>;
|
|
9668
9692
|
/**
|
|
9669
|
-
*
|
|
9670
|
-
* @see https://
|
|
9693
|
+
* Enforce sorted JSX props.
|
|
9694
|
+
* @see https://perfectionist.dev/rules/sort-jsx-props
|
|
9671
9695
|
*/
|
|
9672
9696
|
"perfectionist/sort-jsx-props"?: Linter.RuleEntry<PerfectionistSortJsxProps>;
|
|
9673
9697
|
/**
|
|
9674
|
-
*
|
|
9675
|
-
* @see https://
|
|
9698
|
+
* Enforce sorted Map elements.
|
|
9699
|
+
* @see https://perfectionist.dev/rules/sort-maps
|
|
9676
9700
|
*/
|
|
9677
9701
|
"perfectionist/sort-maps"?: Linter.RuleEntry<PerfectionistSortMaps>;
|
|
9678
9702
|
/**
|
|
9679
|
-
*
|
|
9680
|
-
* @see https://
|
|
9703
|
+
* Enforce sorted named exports.
|
|
9704
|
+
* @see https://perfectionist.dev/rules/sort-named-exports
|
|
9681
9705
|
*/
|
|
9682
9706
|
"perfectionist/sort-named-exports"?: Linter.RuleEntry<PerfectionistSortNamedExports>;
|
|
9683
9707
|
/**
|
|
9684
|
-
*
|
|
9685
|
-
* @see https://
|
|
9708
|
+
* Enforce sorted named imports.
|
|
9709
|
+
* @see https://perfectionist.dev/rules/sort-named-imports
|
|
9686
9710
|
*/
|
|
9687
9711
|
"perfectionist/sort-named-imports"?: Linter.RuleEntry<PerfectionistSortNamedImports>;
|
|
9688
9712
|
/**
|
|
9689
|
-
*
|
|
9690
|
-
* @see https://
|
|
9713
|
+
* Enforce sorted object types.
|
|
9714
|
+
* @see https://perfectionist.dev/rules/sort-object-types
|
|
9691
9715
|
*/
|
|
9692
9716
|
"perfectionist/sort-object-types"?: Linter.RuleEntry<PerfectionistSortObjectTypes>;
|
|
9693
9717
|
/**
|
|
9694
|
-
*
|
|
9695
|
-
* @see https://
|
|
9718
|
+
* Enforce sorted objects.
|
|
9719
|
+
* @see https://perfectionist.dev/rules/sort-objects
|
|
9696
9720
|
*/
|
|
9697
9721
|
"perfectionist/sort-objects"?: Linter.RuleEntry<PerfectionistSortObjects>;
|
|
9698
9722
|
/**
|
|
9699
|
-
*
|
|
9700
|
-
* @see https://
|
|
9723
|
+
* Enforce sorted Svelte attributes.
|
|
9724
|
+
* @see https://perfectionist.dev/rules/sort-svelte-attributes
|
|
9701
9725
|
*/
|
|
9702
9726
|
"perfectionist/sort-svelte-attributes"?: Linter.RuleEntry<PerfectionistSortSvelteAttributes>;
|
|
9703
9727
|
/**
|
|
9704
|
-
*
|
|
9705
|
-
* @see https://
|
|
9728
|
+
* Enforce sorted switch cases.
|
|
9729
|
+
* @see https://perfectionist.dev/rules/sort-switch-case
|
|
9730
|
+
*/
|
|
9731
|
+
"perfectionist/sort-switch-case"?: Linter.RuleEntry<PerfectionistSortSwitchCase>;
|
|
9732
|
+
/**
|
|
9733
|
+
* Enforce sorted union types.
|
|
9734
|
+
* @see https://perfectionist.dev/rules/sort-union-types
|
|
9706
9735
|
*/
|
|
9707
9736
|
"perfectionist/sort-union-types"?: Linter.RuleEntry<PerfectionistSortUnionTypes>;
|
|
9708
9737
|
/**
|
|
9709
|
-
*
|
|
9710
|
-
* @see https://
|
|
9738
|
+
* Enforce sorted variable declarations.
|
|
9739
|
+
* @see https://perfectionist.dev/rules/sort-variable-declarations
|
|
9740
|
+
*/
|
|
9741
|
+
"perfectionist/sort-variable-declarations"?: Linter.RuleEntry<PerfectionistSortVariableDeclarations>;
|
|
9742
|
+
/**
|
|
9743
|
+
* Enforce sorted Vue attributes.
|
|
9744
|
+
* @see https://perfectionist.dev/rules/sort-vue-attributes
|
|
9711
9745
|
*/
|
|
9712
9746
|
"perfectionist/sort-vue-attributes"?: Linter.RuleEntry<PerfectionistSortVueAttributes>;
|
|
9713
9747
|
}
|
|
@@ -9719,9 +9753,12 @@ type PerfectionistSortArrayIncludes =
|
|
|
9719
9753
|
| [
|
|
9720
9754
|
{
|
|
9721
9755
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9756
|
+
|
|
9722
9757
|
order?: "asc" | "desc";
|
|
9723
|
-
|
|
9724
|
-
|
|
9758
|
+
|
|
9759
|
+
ignoreCase?: boolean;
|
|
9760
|
+
|
|
9761
|
+
groupKind?: "mixed" | "literals-first" | "spreads-first";
|
|
9725
9762
|
},
|
|
9726
9763
|
];
|
|
9727
9764
|
// ----- perfectionist/sort-astro-attributes -----
|
|
@@ -9729,13 +9766,17 @@ type PerfectionistSortAstroAttributes =
|
|
|
9729
9766
|
| []
|
|
9730
9767
|
| [
|
|
9731
9768
|
{
|
|
9732
|
-
"custom-groups"?: {
|
|
9733
|
-
[k: string]: unknown | undefined;
|
|
9734
|
-
};
|
|
9735
9769
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9770
|
+
|
|
9736
9771
|
order?: "asc" | "desc";
|
|
9737
|
-
|
|
9738
|
-
|
|
9772
|
+
|
|
9773
|
+
ignoreCase?: boolean;
|
|
9774
|
+
|
|
9775
|
+
groups?: (string | string[])[];
|
|
9776
|
+
|
|
9777
|
+
customGroups?: {
|
|
9778
|
+
[k: string]: (string | string[]) | undefined;
|
|
9779
|
+
};
|
|
9739
9780
|
},
|
|
9740
9781
|
];
|
|
9741
9782
|
// ----- perfectionist/sort-classes -----
|
|
@@ -9743,13 +9784,19 @@ type PerfectionistSortClasses =
|
|
|
9743
9784
|
| []
|
|
9744
9785
|
| [
|
|
9745
9786
|
{
|
|
9746
|
-
"custom-groups"?: {
|
|
9747
|
-
[k: string]: unknown | undefined;
|
|
9748
|
-
};
|
|
9749
9787
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9750
|
-
|
|
9788
|
+
|
|
9751
9789
|
order?: "asc" | "desc";
|
|
9752
|
-
|
|
9790
|
+
|
|
9791
|
+
ignoreCase?: boolean;
|
|
9792
|
+
|
|
9793
|
+
partitionByComment?: string[] | boolean | string;
|
|
9794
|
+
|
|
9795
|
+
groups?: (string | string[])[];
|
|
9796
|
+
|
|
9797
|
+
customGroups?: {
|
|
9798
|
+
[k: string]: (string | string[]) | undefined;
|
|
9799
|
+
};
|
|
9753
9800
|
},
|
|
9754
9801
|
];
|
|
9755
9802
|
// ----- perfectionist/sort-enums -----
|
|
@@ -9757,10 +9804,13 @@ type PerfectionistSortEnums =
|
|
|
9757
9804
|
| []
|
|
9758
9805
|
| [
|
|
9759
9806
|
{
|
|
9760
|
-
"partition-by-comment"?: boolean | string | unknown[];
|
|
9761
9807
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9762
|
-
|
|
9808
|
+
|
|
9763
9809
|
order?: "asc" | "desc";
|
|
9810
|
+
|
|
9811
|
+
ignoreCase?: boolean;
|
|
9812
|
+
|
|
9813
|
+
partitionByComment?: string[] | boolean | string;
|
|
9764
9814
|
},
|
|
9765
9815
|
];
|
|
9766
9816
|
// ----- perfectionist/sort-exports -----
|
|
@@ -9769,15 +9819,31 @@ type PerfectionistSortExports =
|
|
|
9769
9819
|
| [
|
|
9770
9820
|
{
|
|
9771
9821
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9822
|
+
|
|
9772
9823
|
order?: "asc" | "desc";
|
|
9773
|
-
|
|
9824
|
+
|
|
9825
|
+
ignoreCase?: boolean;
|
|
9774
9826
|
},
|
|
9775
9827
|
];
|
|
9776
9828
|
// ----- perfectionist/sort-imports -----
|
|
9777
9829
|
type PerfectionistSortImports = [] | [_PerfectionistSortImportsSortImports];
|
|
9778
9830
|
type _PerfectionistSortImportsSortImports =
|
|
9779
9831
|
_PerfectionistSortImportsMaxLineLengthRequiresLineLengthType & {
|
|
9780
|
-
"
|
|
9832
|
+
type?: "alphabetical" | "natural" | "line-length";
|
|
9833
|
+
|
|
9834
|
+
order?: "asc" | "desc";
|
|
9835
|
+
|
|
9836
|
+
ignoreCase?: boolean;
|
|
9837
|
+
|
|
9838
|
+
internalPattern?: string[];
|
|
9839
|
+
|
|
9840
|
+
newlinesBetween?: "ignore" | "always" | "never";
|
|
9841
|
+
|
|
9842
|
+
maxLineLength?: number;
|
|
9843
|
+
|
|
9844
|
+
groups?: (string | string[])[];
|
|
9845
|
+
|
|
9846
|
+
customGroups?: {
|
|
9781
9847
|
type?: {
|
|
9782
9848
|
[k: string]: unknown | undefined;
|
|
9783
9849
|
};
|
|
@@ -9785,13 +9851,8 @@ type _PerfectionistSortImportsSortImports =
|
|
|
9785
9851
|
[k: string]: unknown | undefined;
|
|
9786
9852
|
};
|
|
9787
9853
|
};
|
|
9788
|
-
|
|
9789
|
-
|
|
9790
|
-
"ignore-case"?: boolean;
|
|
9791
|
-
groups?: unknown[];
|
|
9792
|
-
"internal-pattern"?: string[];
|
|
9793
|
-
"newlines-between"?: "ignore" | "always" | "never";
|
|
9794
|
-
"max-line-length"?: number;
|
|
9854
|
+
|
|
9855
|
+
environment?: "node" | "bun";
|
|
9795
9856
|
};
|
|
9796
9857
|
type _PerfectionistSortImportsMaxLineLengthRequiresLineLengthType =
|
|
9797
9858
|
| {
|
|
@@ -9807,16 +9868,23 @@ type PerfectionistSortInterfaces =
|
|
|
9807
9868
|
| []
|
|
9808
9869
|
| [
|
|
9809
9870
|
{
|
|
9810
|
-
"custom-groups"?: {
|
|
9811
|
-
[k: string]: unknown | undefined;
|
|
9812
|
-
};
|
|
9813
|
-
"optionality-order"?: "ignore" | "optional-first" | "required-first";
|
|
9814
9871
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9872
|
+
|
|
9815
9873
|
order?: "asc" | "desc";
|
|
9816
|
-
|
|
9817
|
-
|
|
9818
|
-
|
|
9819
|
-
|
|
9874
|
+
|
|
9875
|
+
ignoreCase?: boolean;
|
|
9876
|
+
|
|
9877
|
+
ignorePattern?: string[];
|
|
9878
|
+
|
|
9879
|
+
partitionByNewLine?: boolean;
|
|
9880
|
+
|
|
9881
|
+
groupKind?: "mixed" | "optional-first" | "required-first";
|
|
9882
|
+
|
|
9883
|
+
groups?: (string | string[])[];
|
|
9884
|
+
|
|
9885
|
+
customGroups?: {
|
|
9886
|
+
[k: string]: (string | string[]) | undefined;
|
|
9887
|
+
};
|
|
9820
9888
|
},
|
|
9821
9889
|
];
|
|
9822
9890
|
// ----- perfectionist/sort-intersection-types -----
|
|
@@ -9825,8 +9893,12 @@ type PerfectionistSortIntersectionTypes =
|
|
|
9825
9893
|
| [
|
|
9826
9894
|
{
|
|
9827
9895
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9896
|
+
|
|
9828
9897
|
order?: "asc" | "desc";
|
|
9829
|
-
|
|
9898
|
+
|
|
9899
|
+
ignoreCase?: boolean;
|
|
9900
|
+
|
|
9901
|
+
groups?: (string | string[])[];
|
|
9830
9902
|
},
|
|
9831
9903
|
];
|
|
9832
9904
|
// ----- perfectionist/sort-jsx-props -----
|
|
@@ -9834,13 +9906,19 @@ type PerfectionistSortJsxProps =
|
|
|
9834
9906
|
| []
|
|
9835
9907
|
| [
|
|
9836
9908
|
{
|
|
9837
|
-
"custom-groups"?: {
|
|
9838
|
-
[k: string]: unknown | undefined;
|
|
9839
|
-
};
|
|
9840
9909
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9910
|
+
|
|
9841
9911
|
order?: "asc" | "desc";
|
|
9842
|
-
|
|
9843
|
-
|
|
9912
|
+
|
|
9913
|
+
ignoreCase?: boolean;
|
|
9914
|
+
|
|
9915
|
+
ignorePattern?: string[];
|
|
9916
|
+
|
|
9917
|
+
groups?: (string | string[])[];
|
|
9918
|
+
|
|
9919
|
+
customGroups?: {
|
|
9920
|
+
[k: string]: (string | string[]) | undefined;
|
|
9921
|
+
};
|
|
9844
9922
|
},
|
|
9845
9923
|
];
|
|
9846
9924
|
// ----- perfectionist/sort-maps -----
|
|
@@ -9849,8 +9927,10 @@ type PerfectionistSortMaps =
|
|
|
9849
9927
|
| [
|
|
9850
9928
|
{
|
|
9851
9929
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9930
|
+
|
|
9852
9931
|
order?: "asc" | "desc";
|
|
9853
|
-
|
|
9932
|
+
|
|
9933
|
+
ignoreCase?: boolean;
|
|
9854
9934
|
},
|
|
9855
9935
|
];
|
|
9856
9936
|
// ----- perfectionist/sort-named-exports -----
|
|
@@ -9859,9 +9939,12 @@ type PerfectionistSortNamedExports =
|
|
|
9859
9939
|
| [
|
|
9860
9940
|
{
|
|
9861
9941
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9942
|
+
|
|
9862
9943
|
order?: "asc" | "desc";
|
|
9863
|
-
|
|
9864
|
-
|
|
9944
|
+
|
|
9945
|
+
ignoreCase?: boolean;
|
|
9946
|
+
|
|
9947
|
+
groupKind?: "mixed" | "values-first" | "types-first";
|
|
9865
9948
|
},
|
|
9866
9949
|
];
|
|
9867
9950
|
// ----- perfectionist/sort-named-imports -----
|
|
@@ -9870,10 +9953,14 @@ type PerfectionistSortNamedImports =
|
|
|
9870
9953
|
| [
|
|
9871
9954
|
{
|
|
9872
9955
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9956
|
+
|
|
9873
9957
|
order?: "asc" | "desc";
|
|
9874
|
-
|
|
9875
|
-
|
|
9876
|
-
|
|
9958
|
+
|
|
9959
|
+
ignoreCase?: boolean;
|
|
9960
|
+
|
|
9961
|
+
ignoreAlias?: boolean;
|
|
9962
|
+
|
|
9963
|
+
groupKind?: "mixed" | "values-first" | "types-first";
|
|
9877
9964
|
},
|
|
9878
9965
|
];
|
|
9879
9966
|
// ----- perfectionist/sort-object-types -----
|
|
@@ -9881,14 +9968,21 @@ type PerfectionistSortObjectTypes =
|
|
|
9881
9968
|
| []
|
|
9882
9969
|
| [
|
|
9883
9970
|
{
|
|
9884
|
-
"custom-groups"?: {
|
|
9885
|
-
[k: string]: unknown | undefined;
|
|
9886
|
-
};
|
|
9887
9971
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9972
|
+
|
|
9888
9973
|
order?: "asc" | "desc";
|
|
9889
|
-
|
|
9890
|
-
|
|
9891
|
-
|
|
9974
|
+
|
|
9975
|
+
ignoreCase?: boolean;
|
|
9976
|
+
|
|
9977
|
+
partitionByNewLine?: boolean;
|
|
9978
|
+
|
|
9979
|
+
groupKind?: "mixed" | "required-first" | "optional-first";
|
|
9980
|
+
|
|
9981
|
+
groups?: (string | string[])[];
|
|
9982
|
+
|
|
9983
|
+
customGroups?: {
|
|
9984
|
+
[k: string]: (string | string[]) | undefined;
|
|
9985
|
+
};
|
|
9892
9986
|
},
|
|
9893
9987
|
];
|
|
9894
9988
|
// ----- perfectionist/sort-objects -----
|
|
@@ -9896,17 +9990,27 @@ type PerfectionistSortObjects =
|
|
|
9896
9990
|
| []
|
|
9897
9991
|
| [
|
|
9898
9992
|
{
|
|
9899
|
-
"custom-groups"?: {
|
|
9900
|
-
[k: string]: unknown | undefined;
|
|
9901
|
-
};
|
|
9902
|
-
"partition-by-comment"?: boolean | string | unknown[];
|
|
9903
|
-
"partition-by-new-line"?: boolean;
|
|
9904
|
-
"styled-components"?: boolean;
|
|
9905
9993
|
type?: "alphabetical" | "natural" | "line-length";
|
|
9994
|
+
|
|
9906
9995
|
order?: "asc" | "desc";
|
|
9907
|
-
|
|
9908
|
-
|
|
9909
|
-
|
|
9996
|
+
|
|
9997
|
+
ignoreCase?: boolean;
|
|
9998
|
+
|
|
9999
|
+
partitionByComment?: string[] | boolean | string;
|
|
10000
|
+
|
|
10001
|
+
partitionByNewLine?: boolean;
|
|
10002
|
+
|
|
10003
|
+
styledComponents?: boolean;
|
|
10004
|
+
|
|
10005
|
+
ignorePattern?: string[];
|
|
10006
|
+
|
|
10007
|
+
customIgnore?: unknown[];
|
|
10008
|
+
|
|
10009
|
+
groups?: (string | string[])[];
|
|
10010
|
+
|
|
10011
|
+
customGroups?: {
|
|
10012
|
+
[k: string]: (string | string[]) | undefined;
|
|
10013
|
+
};
|
|
9910
10014
|
},
|
|
9911
10015
|
];
|
|
9912
10016
|
// ----- perfectionist/sort-svelte-attributes -----
|
|
@@ -9914,13 +10018,29 @@ type PerfectionistSortSvelteAttributes =
|
|
|
9914
10018
|
| []
|
|
9915
10019
|
| [
|
|
9916
10020
|
{
|
|
9917
|
-
"
|
|
9918
|
-
|
|
10021
|
+
type?: "alphabetical" | "natural" | "line-length";
|
|
10022
|
+
|
|
10023
|
+
order?: "asc" | "desc";
|
|
10024
|
+
|
|
10025
|
+
ignoreCase?: boolean;
|
|
10026
|
+
|
|
10027
|
+
groups?: (string | string[])[];
|
|
10028
|
+
|
|
10029
|
+
customGroups?: {
|
|
10030
|
+
[k: string]: (string | string[]) | undefined;
|
|
9919
10031
|
};
|
|
10032
|
+
},
|
|
10033
|
+
];
|
|
10034
|
+
// ----- perfectionist/sort-switch-case -----
|
|
10035
|
+
type PerfectionistSortSwitchCase =
|
|
10036
|
+
| []
|
|
10037
|
+
| [
|
|
10038
|
+
{
|
|
9920
10039
|
type?: "alphabetical" | "natural" | "line-length";
|
|
10040
|
+
|
|
9921
10041
|
order?: "asc" | "desc";
|
|
9922
|
-
|
|
9923
|
-
|
|
10042
|
+
|
|
10043
|
+
ignoreCase?: boolean;
|
|
9924
10044
|
},
|
|
9925
10045
|
];
|
|
9926
10046
|
// ----- perfectionist/sort-union-types -----
|
|
@@ -9929,9 +10049,24 @@ type PerfectionistSortUnionTypes =
|
|
|
9929
10049
|
| [
|
|
9930
10050
|
{
|
|
9931
10051
|
type?: "alphabetical" | "natural" | "line-length";
|
|
10052
|
+
|
|
9932
10053
|
order?: "asc" | "desc";
|
|
9933
|
-
|
|
9934
|
-
|
|
10054
|
+
|
|
10055
|
+
ignoreCase?: boolean;
|
|
10056
|
+
|
|
10057
|
+
groups?: (string | string[])[];
|
|
10058
|
+
},
|
|
10059
|
+
];
|
|
10060
|
+
// ----- perfectionist/sort-variable-declarations -----
|
|
10061
|
+
type PerfectionistSortVariableDeclarations =
|
|
10062
|
+
| []
|
|
10063
|
+
| [
|
|
10064
|
+
{
|
|
10065
|
+
type?: "alphabetical" | "natural" | "line-length";
|
|
10066
|
+
|
|
10067
|
+
order?: "asc" | "desc";
|
|
10068
|
+
|
|
10069
|
+
ignoreCase?: boolean;
|
|
9935
10070
|
},
|
|
9936
10071
|
];
|
|
9937
10072
|
// ----- perfectionist/sort-vue-attributes -----
|
|
@@ -9939,13 +10074,17 @@ type PerfectionistSortVueAttributes =
|
|
|
9939
10074
|
| []
|
|
9940
10075
|
| [
|
|
9941
10076
|
{
|
|
9942
|
-
"custom-groups"?: {
|
|
9943
|
-
[k: string]: unknown | undefined;
|
|
9944
|
-
};
|
|
9945
10077
|
type?: "alphabetical" | "natural" | "line-length";
|
|
10078
|
+
|
|
9946
10079
|
order?: "asc" | "desc";
|
|
9947
|
-
|
|
9948
|
-
|
|
10080
|
+
|
|
10081
|
+
ignoreCase?: boolean;
|
|
10082
|
+
|
|
10083
|
+
groups?: (string | string[])[];
|
|
10084
|
+
|
|
10085
|
+
customGroups?: {
|
|
10086
|
+
[k: string]: (string | string[]) | undefined;
|
|
10087
|
+
};
|
|
9949
10088
|
},
|
|
9950
10089
|
];
|
|
9951
10090
|
|
|
@@ -10060,7 +10199,7 @@ interface ReactRuleOptions {
|
|
|
10060
10199
|
* Enforce closing tag location for multiline JSX
|
|
10061
10200
|
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/jsx-closing-tag-location.md
|
|
10062
10201
|
*/
|
|
10063
|
-
"react/jsx-closing-tag-location"?: Linter.RuleEntry<
|
|
10202
|
+
"react/jsx-closing-tag-location"?: Linter.RuleEntry<ReactJsxClosingTagLocation>;
|
|
10064
10203
|
/**
|
|
10065
10204
|
* Disallow unnecessary JSX expressions when literals alone are sufficient or enforce JSX expressions on literals in JSX children or attributes
|
|
10066
10205
|
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/jsx-curly-brace-presence.md
|
|
@@ -10196,6 +10335,11 @@ interface ReactRuleOptions {
|
|
|
10196
10335
|
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/jsx-props-no-multi-spaces.md
|
|
10197
10336
|
*/
|
|
10198
10337
|
"react/jsx-props-no-multi-spaces"?: Linter.RuleEntry<[]>;
|
|
10338
|
+
/**
|
|
10339
|
+
* Disallow JSX prop spreading the same identifier multiple times
|
|
10340
|
+
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/jsx-props-no-spread-multi.md
|
|
10341
|
+
*/
|
|
10342
|
+
"react/jsx-props-no-spread-multi"?: Linter.RuleEntry<[]>;
|
|
10199
10343
|
/**
|
|
10200
10344
|
* Disallow JSX prop spreading
|
|
10201
10345
|
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/jsx-props-no-spreading.md
|
|
@@ -10267,7 +10411,7 @@ interface ReactRuleOptions {
|
|
|
10267
10411
|
* Disallow usage of dangerous JSX properties
|
|
10268
10412
|
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/no-danger.md
|
|
10269
10413
|
*/
|
|
10270
|
-
"react/no-danger"?: Linter.RuleEntry<
|
|
10414
|
+
"react/no-danger"?: Linter.RuleEntry<ReactNoDanger>;
|
|
10271
10415
|
/**
|
|
10272
10416
|
* Disallow when a DOM element is using both children and dangerouslySetInnerHTML
|
|
10273
10417
|
* @see https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/no-danger-with-children.md
|
|
@@ -10573,6 +10717,17 @@ type ReactForbidComponentProps =
|
|
|
10573
10717
|
| {
|
|
10574
10718
|
propName?: string;
|
|
10575
10719
|
|
|
10720
|
+
disallowedFor: [string, ...string[]];
|
|
10721
|
+
message?: string;
|
|
10722
|
+
}
|
|
10723
|
+
| {
|
|
10724
|
+
propNamePattern?: string;
|
|
10725
|
+
allowedFor?: string[];
|
|
10726
|
+
message?: string;
|
|
10727
|
+
}
|
|
10728
|
+
| {
|
|
10729
|
+
propNamePattern?: string;
|
|
10730
|
+
|
|
10576
10731
|
disallowedFor: [string, ...string[]];
|
|
10577
10732
|
message?: string;
|
|
10578
10733
|
}
|
|
@@ -10704,6 +10859,15 @@ type ReactJsxClosingBracketLocation =
|
|
|
10704
10859
|
| false;
|
|
10705
10860
|
},
|
|
10706
10861
|
];
|
|
10862
|
+
// ----- react/jsx-closing-tag-location -----
|
|
10863
|
+
type ReactJsxClosingTagLocation =
|
|
10864
|
+
| []
|
|
10865
|
+
| [
|
|
10866
|
+
| ("tag-aligned" | "line-aligned")
|
|
10867
|
+
| {
|
|
10868
|
+
location?: "tag-aligned" | "line-aligned";
|
|
10869
|
+
},
|
|
10870
|
+
];
|
|
10707
10871
|
// ----- react/jsx-curly-brace-presence -----
|
|
10708
10872
|
type ReactJsxCurlyBracePresence =
|
|
10709
10873
|
| []
|
|
@@ -10792,24 +10956,31 @@ type ReactJsxHandlerNames =
|
|
|
10792
10956
|
eventHandlerPropPrefix?: string;
|
|
10793
10957
|
checkLocalVariables?: boolean;
|
|
10794
10958
|
checkInlineFunction?: boolean;
|
|
10959
|
+
ignoreComponentNames?: string[];
|
|
10795
10960
|
}
|
|
10796
10961
|
| {
|
|
10797
10962
|
eventHandlerPrefix?: string;
|
|
10798
10963
|
eventHandlerPropPrefix?: false;
|
|
10799
10964
|
checkLocalVariables?: boolean;
|
|
10800
10965
|
checkInlineFunction?: boolean;
|
|
10966
|
+
ignoreComponentNames?: string[];
|
|
10801
10967
|
}
|
|
10802
10968
|
| {
|
|
10803
10969
|
eventHandlerPrefix?: false;
|
|
10804
10970
|
eventHandlerPropPrefix?: string;
|
|
10805
10971
|
checkLocalVariables?: boolean;
|
|
10806
10972
|
checkInlineFunction?: boolean;
|
|
10973
|
+
ignoreComponentNames?: string[];
|
|
10807
10974
|
}
|
|
10808
10975
|
| {
|
|
10809
10976
|
checkLocalVariables?: boolean;
|
|
10810
10977
|
}
|
|
10811
10978
|
| {
|
|
10812
10979
|
checkInlineFunction?: boolean;
|
|
10980
|
+
}
|
|
10981
|
+
| {
|
|
10982
|
+
ignoreComponentNames?: string[];
|
|
10983
|
+
[k: string]: unknown | undefined;
|
|
10813
10984
|
},
|
|
10814
10985
|
];
|
|
10815
10986
|
// ----- react/jsx-indent -----
|
|
@@ -11103,6 +11274,15 @@ type ReactNoChildrenProp =
|
|
|
11103
11274
|
allowFunctions?: boolean;
|
|
11104
11275
|
},
|
|
11105
11276
|
];
|
|
11277
|
+
// ----- react/no-danger -----
|
|
11278
|
+
type ReactNoDanger =
|
|
11279
|
+
| []
|
|
11280
|
+
| [
|
|
11281
|
+
{
|
|
11282
|
+
customComponentNames?: string[];
|
|
11283
|
+
[k: string]: unknown | undefined;
|
|
11284
|
+
},
|
|
11285
|
+
];
|
|
11106
11286
|
// ----- react/no-did-mount-set-state -----
|
|
11107
11287
|
type ReactNoDidMountSetState = [] | ["disallow-in-func"];
|
|
11108
11288
|
// ----- react/no-did-update-set-state -----
|
|
@@ -13216,6 +13396,7 @@ type _StylisticPaddingLineBetweenStatementsStatementType =
|
|
|
13216
13396
|
| "with"
|
|
13217
13397
|
| "cjs-export"
|
|
13218
13398
|
| "cjs-import"
|
|
13399
|
+
| "enum"
|
|
13219
13400
|
| "interface"
|
|
13220
13401
|
| "type"
|
|
13221
13402
|
| "function-overload"
|
|
@@ -13262,6 +13443,7 @@ type _StylisticPaddingLineBetweenStatementsStatementType =
|
|
|
13262
13443
|
| "with"
|
|
13263
13444
|
| "cjs-export"
|
|
13264
13445
|
| "cjs-import"
|
|
13446
|
+
| "enum"
|
|
13265
13447
|
| "interface"
|
|
13266
13448
|
| "type"
|
|
13267
13449
|
| "function-overload"
|
|
@@ -13307,6 +13489,7 @@ type _StylisticPaddingLineBetweenStatementsStatementType =
|
|
|
13307
13489
|
| "with"
|
|
13308
13490
|
| "cjs-export"
|
|
13309
13491
|
| "cjs-import"
|
|
13492
|
+
| "enum"
|
|
13310
13493
|
| "interface"
|
|
13311
13494
|
| "type"
|
|
13312
13495
|
| "function-overload"
|
|
@@ -14637,6 +14820,11 @@ interface TypescriptRuleOptions {
|
|
|
14637
14820
|
* @see https://typescript-eslint.io/rules/no-unsafe-enum-comparison
|
|
14638
14821
|
*/
|
|
14639
14822
|
"@typescript-eslint/no-unsafe-enum-comparison"?: Linter.RuleEntry<[]>;
|
|
14823
|
+
/**
|
|
14824
|
+
* Disallow using the unsafe built-in Function type
|
|
14825
|
+
* @see https://typescript-eslint.io/rules/no-unsafe-function-type
|
|
14826
|
+
*/
|
|
14827
|
+
"@typescript-eslint/no-unsafe-function-type"?: Linter.RuleEntry<[]>;
|
|
14640
14828
|
/**
|
|
14641
14829
|
* Disallow member access on a value with type `any`
|
|
14642
14830
|
* @see https://typescript-eslint.io/rules/no-unsafe-member-access
|
|
@@ -14688,6 +14876,11 @@ interface TypescriptRuleOptions {
|
|
|
14688
14876
|
* @see https://typescript-eslint.io/rules/no-var-requires
|
|
14689
14877
|
*/
|
|
14690
14878
|
"@typescript-eslint/no-var-requires"?: Linter.RuleEntry<TypescriptEslintNoVarRequires>;
|
|
14879
|
+
/**
|
|
14880
|
+
* Disallow using confusing built-in primitive class wrappers
|
|
14881
|
+
* @see https://typescript-eslint.io/rules/no-wrapper-object-types
|
|
14882
|
+
*/
|
|
14883
|
+
"@typescript-eslint/no-wrapper-object-types"?: Linter.RuleEntry<[]>;
|
|
14691
14884
|
/**
|
|
14692
14885
|
* Enforce non-null assertions over explicit type casts
|
|
14693
14886
|
* @see https://typescript-eslint.io/rules/non-nullable-type-assertion-style
|
|
@@ -14922,42 +15115,42 @@ interface TypescriptRuleOptions {
|
|
|
14922
15115
|
>;
|
|
14923
15116
|
/**
|
|
14924
15117
|
* Enforce or ban the use of inline type-only markers for named imports.
|
|
14925
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15118
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/consistent-type-specifier-style.md
|
|
14926
15119
|
*/
|
|
14927
15120
|
"import/consistent-type-specifier-style"?: Linter.RuleEntry<ImportConsistentTypeSpecifierStyle>;
|
|
14928
15121
|
/**
|
|
14929
15122
|
* Ensure a default export is present, given a default import.
|
|
14930
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15123
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/default.md
|
|
14931
15124
|
*/
|
|
14932
15125
|
"import/default"?: Linter.RuleEntry<[]>;
|
|
14933
15126
|
/**
|
|
14934
15127
|
* Enforce a leading comment with the webpackChunkName for dynamic imports.
|
|
14935
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15128
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/dynamic-import-chunkname.md
|
|
14936
15129
|
*/
|
|
14937
15130
|
"import/dynamic-import-chunkname"?: Linter.RuleEntry<ImportDynamicImportChunkname>;
|
|
14938
15131
|
/**
|
|
14939
15132
|
* Forbid any invalid exports, i.e. re-export of the same name.
|
|
14940
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15133
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/export.md
|
|
14941
15134
|
*/
|
|
14942
15135
|
"import/export"?: Linter.RuleEntry<[]>;
|
|
14943
15136
|
/**
|
|
14944
15137
|
* Ensure all exports appear after other statements.
|
|
14945
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15138
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/exports-last.md
|
|
14946
15139
|
*/
|
|
14947
15140
|
"import/exports-last"?: Linter.RuleEntry<[]>;
|
|
14948
15141
|
/**
|
|
14949
15142
|
* Ensure consistent use of file extension within the import path.
|
|
14950
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15143
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/extensions.md
|
|
14951
15144
|
*/
|
|
14952
15145
|
"import/extensions"?: Linter.RuleEntry<ImportExtensions>;
|
|
14953
15146
|
/**
|
|
14954
15147
|
* Ensure all imports appear before other statements.
|
|
14955
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15148
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/first.md
|
|
14956
15149
|
*/
|
|
14957
15150
|
"import/first"?: Linter.RuleEntry<ImportFirst>;
|
|
14958
15151
|
/**
|
|
14959
15152
|
* Prefer named exports to be grouped together in a single export declaration.
|
|
14960
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15153
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/group-exports.md
|
|
14961
15154
|
*/
|
|
14962
15155
|
"import/group-exports"?: Linter.RuleEntry<[]>;
|
|
14963
15156
|
/**
|
|
@@ -14968,182 +15161,182 @@ interface TypescriptRuleOptions {
|
|
|
14968
15161
|
"import/imports-first"?: Linter.RuleEntry<ImportImportsFirst>;
|
|
14969
15162
|
/**
|
|
14970
15163
|
* Enforce the maximum number of dependencies a module can have.
|
|
14971
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15164
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/max-dependencies.md
|
|
14972
15165
|
*/
|
|
14973
15166
|
"import/max-dependencies"?: Linter.RuleEntry<ImportMaxDependencies>;
|
|
14974
15167
|
/**
|
|
14975
15168
|
* Ensure named imports correspond to a named export in the remote file.
|
|
14976
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15169
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/named.md
|
|
14977
15170
|
*/
|
|
14978
15171
|
"import/named"?: Linter.RuleEntry<ImportNamed>;
|
|
14979
15172
|
/**
|
|
14980
15173
|
* Ensure imported namespaces contain dereferenced properties as they are dereferenced.
|
|
14981
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15174
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/namespace.md
|
|
14982
15175
|
*/
|
|
14983
15176
|
"import/namespace"?: Linter.RuleEntry<ImportNamespace>;
|
|
14984
15177
|
/**
|
|
14985
15178
|
* Enforce a newline after import statements.
|
|
14986
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15179
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/newline-after-import.md
|
|
14987
15180
|
*/
|
|
14988
15181
|
"import/newline-after-import"?: Linter.RuleEntry<ImportNewlineAfterImport>;
|
|
14989
15182
|
/**
|
|
14990
15183
|
* Forbid import of modules using absolute paths.
|
|
14991
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15184
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-absolute-path.md
|
|
14992
15185
|
*/
|
|
14993
15186
|
"import/no-absolute-path"?: Linter.RuleEntry<ImportNoAbsolutePath>;
|
|
14994
15187
|
/**
|
|
14995
15188
|
* Forbid AMD `require` and `define` calls.
|
|
14996
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15189
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-amd.md
|
|
14997
15190
|
*/
|
|
14998
15191
|
"import/no-amd"?: Linter.RuleEntry<[]>;
|
|
14999
15192
|
/**
|
|
15000
15193
|
* Forbid anonymous values as default exports.
|
|
15001
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15194
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-anonymous-default-export.md
|
|
15002
15195
|
*/
|
|
15003
15196
|
"import/no-anonymous-default-export"?: Linter.RuleEntry<ImportNoAnonymousDefaultExport>;
|
|
15004
15197
|
/**
|
|
15005
15198
|
* Forbid CommonJS `require` calls and `module.exports` or `exports.*`.
|
|
15006
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15199
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-commonjs.md
|
|
15007
15200
|
*/
|
|
15008
15201
|
"import/no-commonjs"?: Linter.RuleEntry<ImportNoCommonjs>;
|
|
15009
15202
|
/**
|
|
15010
15203
|
* Forbid a module from importing a module with a dependency path back to itself.
|
|
15011
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15204
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-cycle.md
|
|
15012
15205
|
*/
|
|
15013
15206
|
"import/no-cycle"?: Linter.RuleEntry<ImportNoCycle>;
|
|
15014
15207
|
/**
|
|
15015
15208
|
* Forbid default exports.
|
|
15016
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15209
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-default-export.md
|
|
15017
15210
|
*/
|
|
15018
15211
|
"import/no-default-export"?: Linter.RuleEntry<[]>;
|
|
15019
15212
|
/**
|
|
15020
15213
|
* Forbid imported names marked with `@deprecated` documentation tag.
|
|
15021
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15214
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-deprecated.md
|
|
15022
15215
|
*/
|
|
15023
15216
|
"import/no-deprecated"?: Linter.RuleEntry<[]>;
|
|
15024
15217
|
/**
|
|
15025
15218
|
* Forbid repeated import of the same module in multiple places.
|
|
15026
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15219
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-duplicates.md
|
|
15027
15220
|
*/
|
|
15028
15221
|
"import/no-duplicates"?: Linter.RuleEntry<ImportNoDuplicates>;
|
|
15029
15222
|
/**
|
|
15030
15223
|
* Forbid `require()` calls with expressions.
|
|
15031
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15224
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-dynamic-require.md
|
|
15032
15225
|
*/
|
|
15033
15226
|
"import/no-dynamic-require"?: Linter.RuleEntry<ImportNoDynamicRequire>;
|
|
15034
15227
|
/**
|
|
15035
15228
|
* Forbid empty named import blocks.
|
|
15036
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15229
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-empty-named-blocks.md
|
|
15037
15230
|
*/
|
|
15038
15231
|
"import/no-empty-named-blocks"?: Linter.RuleEntry<[]>;
|
|
15039
15232
|
/**
|
|
15040
15233
|
* Forbid the use of extraneous packages.
|
|
15041
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15234
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-extraneous-dependencies.md
|
|
15042
15235
|
*/
|
|
15043
15236
|
"import/no-extraneous-dependencies"?: Linter.RuleEntry<ImportNoExtraneousDependencies>;
|
|
15044
15237
|
/**
|
|
15045
15238
|
* Forbid import statements with CommonJS module.exports.
|
|
15046
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15239
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-import-module-exports.md
|
|
15047
15240
|
*/
|
|
15048
15241
|
"import/no-import-module-exports"?: Linter.RuleEntry<ImportNoImportModuleExports>;
|
|
15049
15242
|
/**
|
|
15050
15243
|
* Forbid importing the submodules of other modules.
|
|
15051
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15244
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-internal-modules.md
|
|
15052
15245
|
*/
|
|
15053
15246
|
"import/no-internal-modules"?: Linter.RuleEntry<ImportNoInternalModules>;
|
|
15054
15247
|
/**
|
|
15055
15248
|
* Forbid the use of mutable exports with `var` or `let`.
|
|
15056
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15249
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-mutable-exports.md
|
|
15057
15250
|
*/
|
|
15058
15251
|
"import/no-mutable-exports"?: Linter.RuleEntry<[]>;
|
|
15059
15252
|
/**
|
|
15060
15253
|
* Forbid use of exported name as identifier of default export.
|
|
15061
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15254
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-as-default.md
|
|
15062
15255
|
*/
|
|
15063
15256
|
"import/no-named-as-default"?: Linter.RuleEntry<[]>;
|
|
15064
15257
|
/**
|
|
15065
15258
|
* Forbid use of exported name as property of default export.
|
|
15066
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15259
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-as-default-member.md
|
|
15067
15260
|
*/
|
|
15068
15261
|
"import/no-named-as-default-member"?: Linter.RuleEntry<[]>;
|
|
15069
15262
|
/**
|
|
15070
15263
|
* Forbid named default exports.
|
|
15071
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15264
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-default.md
|
|
15072
15265
|
*/
|
|
15073
15266
|
"import/no-named-default"?: Linter.RuleEntry<[]>;
|
|
15074
15267
|
/**
|
|
15075
15268
|
* Forbid named exports.
|
|
15076
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15269
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-export.md
|
|
15077
15270
|
*/
|
|
15078
15271
|
"import/no-named-export"?: Linter.RuleEntry<[]>;
|
|
15079
15272
|
/**
|
|
15080
15273
|
* Forbid namespace (a.k.a. "wildcard" `*`) imports.
|
|
15081
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15274
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-namespace.md
|
|
15082
15275
|
*/
|
|
15083
15276
|
"import/no-namespace"?: Linter.RuleEntry<ImportNoNamespace>;
|
|
15084
15277
|
/**
|
|
15085
15278
|
* Forbid Node.js builtin modules.
|
|
15086
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15279
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-nodejs-modules.md
|
|
15087
15280
|
*/
|
|
15088
15281
|
"import/no-nodejs-modules"?: Linter.RuleEntry<ImportNoNodejsModules>;
|
|
15089
15282
|
/**
|
|
15090
15283
|
* Forbid importing packages through relative paths.
|
|
15091
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15284
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-relative-packages.md
|
|
15092
15285
|
*/
|
|
15093
15286
|
"import/no-relative-packages"?: Linter.RuleEntry<ImportNoRelativePackages>;
|
|
15094
15287
|
/**
|
|
15095
15288
|
* Forbid importing modules from parent directories.
|
|
15096
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15289
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-relative-parent-imports.md
|
|
15097
15290
|
*/
|
|
15098
15291
|
"import/no-relative-parent-imports"?: Linter.RuleEntry<ImportNoRelativeParentImports>;
|
|
15099
15292
|
/**
|
|
15100
15293
|
* Enforce which files can be imported in a given folder.
|
|
15101
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15294
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-restricted-paths.md
|
|
15102
15295
|
*/
|
|
15103
15296
|
"import/no-restricted-paths"?: Linter.RuleEntry<ImportNoRestrictedPaths>;
|
|
15104
15297
|
/**
|
|
15105
15298
|
* Forbid a module from importing itself.
|
|
15106
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15299
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-self-import.md
|
|
15107
15300
|
*/
|
|
15108
15301
|
"import/no-self-import"?: Linter.RuleEntry<[]>;
|
|
15109
15302
|
/**
|
|
15110
15303
|
* Forbid unassigned imports.
|
|
15111
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15304
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unassigned-import.md
|
|
15112
15305
|
*/
|
|
15113
15306
|
"import/no-unassigned-import"?: Linter.RuleEntry<ImportNoUnassignedImport>;
|
|
15114
15307
|
/**
|
|
15115
15308
|
* Ensure imports point to a file/module that can be resolved.
|
|
15116
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15309
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unresolved.md
|
|
15117
15310
|
*/
|
|
15118
15311
|
"import/no-unresolved"?: Linter.RuleEntry<ImportNoUnresolved>;
|
|
15119
15312
|
/**
|
|
15120
15313
|
* Forbid modules without exports, or exports without matching import in another module.
|
|
15121
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15314
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unused-modules.md
|
|
15122
15315
|
*/
|
|
15123
15316
|
"import/no-unused-modules"?: Linter.RuleEntry<ImportNoUnusedModules>;
|
|
15124
15317
|
/**
|
|
15125
15318
|
* Forbid unnecessary path segments in import and require statements.
|
|
15126
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15319
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-useless-path-segments.md
|
|
15127
15320
|
*/
|
|
15128
15321
|
"import/no-useless-path-segments"?: Linter.RuleEntry<ImportNoUselessPathSegments>;
|
|
15129
15322
|
/**
|
|
15130
15323
|
* Forbid webpack loader syntax in imports.
|
|
15131
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15324
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-webpack-loader-syntax.md
|
|
15132
15325
|
*/
|
|
15133
15326
|
"import/no-webpack-loader-syntax"?: Linter.RuleEntry<[]>;
|
|
15134
15327
|
/**
|
|
15135
15328
|
* Enforce a convention in module import order.
|
|
15136
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15329
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/order.md
|
|
15137
15330
|
*/
|
|
15138
15331
|
"import/order"?: Linter.RuleEntry<ImportOrder>;
|
|
15139
15332
|
/**
|
|
15140
15333
|
* Prefer a default export if module exports a single name or multiple names.
|
|
15141
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15334
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/prefer-default-export.md
|
|
15142
15335
|
*/
|
|
15143
15336
|
"import/prefer-default-export"?: Linter.RuleEntry<ImportPreferDefaultExport>;
|
|
15144
15337
|
/**
|
|
15145
15338
|
* Forbid potentially ambiguous parse goal (`script` vs. `module`).
|
|
15146
|
-
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/
|
|
15339
|
+
* @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/unambiguous.md
|
|
15147
15340
|
*/
|
|
15148
15341
|
"import/unambiguous"?: Linter.RuleEntry<[]>;
|
|
15149
15342
|
}
|
|
@@ -19269,7 +19462,9 @@ type TypescriptEslintRestrictTemplateExpressions =
|
|
|
19269
19462
|
},
|
|
19270
19463
|
];
|
|
19271
19464
|
// ----- @typescript-eslint/return-await -----
|
|
19272
|
-
type TypescriptEslintReturnAwait =
|
|
19465
|
+
type TypescriptEslintReturnAwait =
|
|
19466
|
+
| []
|
|
19467
|
+
| ["in-try-catch" | "always" | "never" | "error-handling-correctness-only"];
|
|
19273
19468
|
// ----- @typescript-eslint/semi -----
|
|
19274
19469
|
type TypescriptEslintSemi =
|
|
19275
19470
|
| []
|
|
@@ -19807,682 +20002,687 @@ type ImportPreferDefaultExport =
|
|
|
19807
20002
|
interface UnicornRuleOptions {
|
|
19808
20003
|
/**
|
|
19809
20004
|
* Improve regexes by making them shorter, consistent, and safer.
|
|
19810
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20005
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/better-regex.md
|
|
19811
20006
|
*/
|
|
19812
20007
|
"unicorn/better-regex"?: Linter.RuleEntry<UnicornBetterRegex>;
|
|
19813
20008
|
/**
|
|
19814
20009
|
* Enforce a specific parameter name in catch clauses.
|
|
19815
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20010
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/catch-error-name.md
|
|
19816
20011
|
*/
|
|
19817
20012
|
"unicorn/catch-error-name"?: Linter.RuleEntry<UnicornCatchErrorName>;
|
|
19818
20013
|
/**
|
|
19819
20014
|
* Use destructured variables over properties.
|
|
19820
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20015
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/consistent-destructuring.md
|
|
19821
20016
|
*/
|
|
19822
20017
|
"unicorn/consistent-destructuring"?: Linter.RuleEntry<[]>;
|
|
19823
20018
|
/**
|
|
19824
20019
|
* Prefer consistent types when spreading a ternary in an array literal.
|
|
19825
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20020
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/consistent-empty-array-spread.md
|
|
19826
20021
|
*/
|
|
19827
20022
|
"unicorn/consistent-empty-array-spread"?: Linter.RuleEntry<[]>;
|
|
19828
20023
|
/**
|
|
19829
20024
|
* Move function definitions to the highest possible scope.
|
|
19830
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20025
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/consistent-function-scoping.md
|
|
19831
20026
|
*/
|
|
19832
20027
|
"unicorn/consistent-function-scoping"?: Linter.RuleEntry<UnicornConsistentFunctionScoping>;
|
|
19833
20028
|
/**
|
|
19834
20029
|
* Enforce correct `Error` subclassing.
|
|
19835
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20030
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/custom-error-definition.md
|
|
19836
20031
|
*/
|
|
19837
20032
|
"unicorn/custom-error-definition"?: Linter.RuleEntry<[]>;
|
|
19838
20033
|
/**
|
|
19839
20034
|
* Enforce no spaces between braces.
|
|
19840
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20035
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/empty-brace-spaces.md
|
|
19841
20036
|
*/
|
|
19842
20037
|
"unicorn/empty-brace-spaces"?: Linter.RuleEntry<[]>;
|
|
19843
20038
|
/**
|
|
19844
20039
|
* Enforce passing a `message` value when creating a built-in error.
|
|
19845
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20040
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/error-message.md
|
|
19846
20041
|
*/
|
|
19847
20042
|
"unicorn/error-message"?: Linter.RuleEntry<[]>;
|
|
19848
20043
|
/**
|
|
19849
20044
|
* Require escape sequences to use uppercase values.
|
|
19850
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20045
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/escape-case.md
|
|
19851
20046
|
*/
|
|
19852
20047
|
"unicorn/escape-case"?: Linter.RuleEntry<[]>;
|
|
19853
20048
|
/**
|
|
19854
20049
|
* Add expiration conditions to TODO comments.
|
|
19855
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20050
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/expiring-todo-comments.md
|
|
19856
20051
|
*/
|
|
19857
20052
|
"unicorn/expiring-todo-comments"?: Linter.RuleEntry<UnicornExpiringTodoComments>;
|
|
19858
20053
|
/**
|
|
19859
20054
|
* Enforce explicitly comparing the `length` or `size` property of a value.
|
|
19860
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20055
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/explicit-length-check.md
|
|
19861
20056
|
*/
|
|
19862
20057
|
"unicorn/explicit-length-check"?: Linter.RuleEntry<UnicornExplicitLengthCheck>;
|
|
19863
20058
|
/**
|
|
19864
20059
|
* Enforce a case style for filenames.
|
|
19865
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20060
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/filename-case.md
|
|
19866
20061
|
*/
|
|
19867
20062
|
"unicorn/filename-case"?: Linter.RuleEntry<UnicornFilenameCase>;
|
|
19868
20063
|
/**
|
|
19869
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20064
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#import-index
|
|
19870
20065
|
* @deprecated
|
|
19871
20066
|
*/
|
|
19872
20067
|
"unicorn/import-index"?: Linter.RuleEntry<[]>;
|
|
19873
20068
|
/**
|
|
19874
20069
|
* Enforce specific import styles per module.
|
|
19875
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20070
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/import-style.md
|
|
19876
20071
|
*/
|
|
19877
20072
|
"unicorn/import-style"?: Linter.RuleEntry<UnicornImportStyle>;
|
|
19878
20073
|
/**
|
|
19879
20074
|
* Enforce the use of `new` for all builtins, except `String`, `Number`, `Boolean`, `Symbol` and `BigInt`.
|
|
19880
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20075
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/new-for-builtins.md
|
|
19881
20076
|
*/
|
|
19882
20077
|
"unicorn/new-for-builtins"?: Linter.RuleEntry<[]>;
|
|
19883
20078
|
/**
|
|
19884
20079
|
* Enforce specifying rules to disable in `eslint-disable` comments.
|
|
19885
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20080
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-abusive-eslint-disable.md
|
|
19886
20081
|
*/
|
|
19887
20082
|
"unicorn/no-abusive-eslint-disable"?: Linter.RuleEntry<[]>;
|
|
19888
20083
|
/**
|
|
19889
20084
|
* Disallow anonymous functions and classes as the default export.
|
|
19890
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20085
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-anonymous-default-export.md
|
|
19891
20086
|
*/
|
|
19892
20087
|
"unicorn/no-anonymous-default-export"?: Linter.RuleEntry<[]>;
|
|
19893
20088
|
/**
|
|
19894
20089
|
* Prevent passing a function reference directly to iterator methods.
|
|
19895
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20090
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-array-callback-reference.md
|
|
19896
20091
|
*/
|
|
19897
20092
|
"unicorn/no-array-callback-reference"?: Linter.RuleEntry<[]>;
|
|
19898
20093
|
/**
|
|
19899
20094
|
* Prefer `for…of` over the `forEach` method.
|
|
19900
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20095
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-array-for-each.md
|
|
19901
20096
|
*/
|
|
19902
20097
|
"unicorn/no-array-for-each"?: Linter.RuleEntry<[]>;
|
|
19903
20098
|
/**
|
|
19904
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20099
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#no-array-instanceof
|
|
19905
20100
|
* @deprecated
|
|
19906
20101
|
*/
|
|
19907
20102
|
"unicorn/no-array-instanceof"?: Linter.RuleEntry<[]>;
|
|
19908
20103
|
/**
|
|
19909
20104
|
* Disallow using the `this` argument in array methods.
|
|
19910
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20105
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-array-method-this-argument.md
|
|
19911
20106
|
*/
|
|
19912
20107
|
"unicorn/no-array-method-this-argument"?: Linter.RuleEntry<[]>;
|
|
19913
20108
|
/**
|
|
19914
20109
|
* Enforce combining multiple `Array#push()` into one call.
|
|
19915
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20110
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-array-push-push.md
|
|
19916
20111
|
*/
|
|
19917
20112
|
"unicorn/no-array-push-push"?: Linter.RuleEntry<UnicornNoArrayPushPush>;
|
|
19918
20113
|
/**
|
|
19919
20114
|
* Disallow `Array#reduce()` and `Array#reduceRight()`.
|
|
19920
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20115
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-array-reduce.md
|
|
19921
20116
|
*/
|
|
19922
20117
|
"unicorn/no-array-reduce"?: Linter.RuleEntry<UnicornNoArrayReduce>;
|
|
19923
20118
|
/**
|
|
19924
20119
|
* Disallow member access from await expression.
|
|
19925
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20120
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-await-expression-member.md
|
|
19926
20121
|
*/
|
|
19927
20122
|
"unicorn/no-await-expression-member"?: Linter.RuleEntry<[]>;
|
|
19928
20123
|
/**
|
|
19929
20124
|
* Disallow using `await` in `Promise` method parameters.
|
|
19930
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20125
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-await-in-promise-methods.md
|
|
19931
20126
|
*/
|
|
19932
20127
|
"unicorn/no-await-in-promise-methods"?: Linter.RuleEntry<[]>;
|
|
19933
20128
|
/**
|
|
19934
20129
|
* Do not use leading/trailing space between `console.log` parameters.
|
|
19935
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20130
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-console-spaces.md
|
|
19936
20131
|
*/
|
|
19937
20132
|
"unicorn/no-console-spaces"?: Linter.RuleEntry<[]>;
|
|
19938
20133
|
/**
|
|
19939
20134
|
* Do not use `document.cookie` directly.
|
|
19940
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20135
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-document-cookie.md
|
|
19941
20136
|
*/
|
|
19942
20137
|
"unicorn/no-document-cookie"?: Linter.RuleEntry<[]>;
|
|
19943
20138
|
/**
|
|
19944
20139
|
* Disallow empty files.
|
|
19945
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20140
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-empty-file.md
|
|
19946
20141
|
*/
|
|
19947
20142
|
"unicorn/no-empty-file"?: Linter.RuleEntry<[]>;
|
|
19948
20143
|
/**
|
|
19949
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20144
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#no-fn-reference-in-iterator
|
|
19950
20145
|
* @deprecated
|
|
19951
20146
|
*/
|
|
19952
20147
|
"unicorn/no-fn-reference-in-iterator"?: Linter.RuleEntry<[]>;
|
|
19953
20148
|
/**
|
|
19954
20149
|
* Do not use a `for` loop that can be replaced with a `for-of` loop.
|
|
19955
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20150
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-for-loop.md
|
|
19956
20151
|
*/
|
|
19957
20152
|
"unicorn/no-for-loop"?: Linter.RuleEntry<[]>;
|
|
19958
20153
|
/**
|
|
19959
20154
|
* Enforce the use of Unicode escapes instead of hexadecimal escapes.
|
|
19960
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20155
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-hex-escape.md
|
|
19961
20156
|
*/
|
|
19962
20157
|
"unicorn/no-hex-escape"?: Linter.RuleEntry<[]>;
|
|
19963
20158
|
/**
|
|
19964
20159
|
* Require `Array.isArray()` instead of `instanceof Array`.
|
|
19965
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20160
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-instanceof-array.md
|
|
19966
20161
|
*/
|
|
19967
20162
|
"unicorn/no-instanceof-array"?: Linter.RuleEntry<[]>;
|
|
19968
20163
|
/**
|
|
19969
20164
|
* Disallow invalid options in `fetch()` and `new Request()`.
|
|
19970
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20165
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-invalid-fetch-options.md
|
|
19971
20166
|
*/
|
|
19972
20167
|
"unicorn/no-invalid-fetch-options"?: Linter.RuleEntry<[]>;
|
|
19973
20168
|
/**
|
|
19974
20169
|
* Prevent calling `EventTarget#removeEventListener()` with the result of an expression.
|
|
19975
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20170
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-invalid-remove-event-listener.md
|
|
19976
20171
|
*/
|
|
19977
20172
|
"unicorn/no-invalid-remove-event-listener"?: Linter.RuleEntry<[]>;
|
|
19978
20173
|
/**
|
|
19979
20174
|
* Disallow identifiers starting with `new` or `class`.
|
|
19980
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20175
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-keyword-prefix.md
|
|
19981
20176
|
*/
|
|
19982
20177
|
"unicorn/no-keyword-prefix"?: Linter.RuleEntry<UnicornNoKeywordPrefix>;
|
|
20178
|
+
/**
|
|
20179
|
+
* Disallow using `.length` as the `end` argument of `{Array,String,TypedArray}#slice()`.
|
|
20180
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-length-as-slice-end.md
|
|
20181
|
+
*/
|
|
20182
|
+
"unicorn/no-length-as-slice-end"?: Linter.RuleEntry<[]>;
|
|
19983
20183
|
/**
|
|
19984
20184
|
* Disallow `if` statements as the only statement in `if` blocks without `else`.
|
|
19985
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20185
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-lonely-if.md
|
|
19986
20186
|
*/
|
|
19987
20187
|
"unicorn/no-lonely-if"?: Linter.RuleEntry<[]>;
|
|
19988
20188
|
/**
|
|
19989
20189
|
* Disallow a magic number as the `depth` argument in `Array#flat(…).`
|
|
19990
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20190
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-magic-array-flat-depth.md
|
|
19991
20191
|
*/
|
|
19992
20192
|
"unicorn/no-magic-array-flat-depth"?: Linter.RuleEntry<[]>;
|
|
19993
20193
|
/**
|
|
19994
20194
|
* Disallow negated conditions.
|
|
19995
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20195
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-negated-condition.md
|
|
19996
20196
|
*/
|
|
19997
20197
|
"unicorn/no-negated-condition"?: Linter.RuleEntry<[]>;
|
|
19998
20198
|
/**
|
|
19999
20199
|
* Disallow negated expression in equality check.
|
|
20000
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20200
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-negation-in-equality-check.md
|
|
20001
20201
|
*/
|
|
20002
20202
|
"unicorn/no-negation-in-equality-check"?: Linter.RuleEntry<[]>;
|
|
20003
20203
|
/**
|
|
20004
20204
|
* Disallow nested ternary expressions.
|
|
20005
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20205
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-nested-ternary.md
|
|
20006
20206
|
*/
|
|
20007
20207
|
"unicorn/no-nested-ternary"?: Linter.RuleEntry<[]>;
|
|
20008
20208
|
/**
|
|
20009
20209
|
* Disallow `new Array()`.
|
|
20010
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20210
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-new-array.md
|
|
20011
20211
|
*/
|
|
20012
20212
|
"unicorn/no-new-array"?: Linter.RuleEntry<[]>;
|
|
20013
20213
|
/**
|
|
20014
20214
|
* Enforce the use of `Buffer.from()` and `Buffer.alloc()` instead of the deprecated `new Buffer()`.
|
|
20015
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20215
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-new-buffer.md
|
|
20016
20216
|
*/
|
|
20017
20217
|
"unicorn/no-new-buffer"?: Linter.RuleEntry<[]>;
|
|
20018
20218
|
/**
|
|
20019
20219
|
* Disallow the use of the `null` literal.
|
|
20020
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20220
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-null.md
|
|
20021
20221
|
*/
|
|
20022
20222
|
"unicorn/no-null"?: Linter.RuleEntry<UnicornNoNull>;
|
|
20023
20223
|
/**
|
|
20024
20224
|
* Disallow the use of objects as default parameters.
|
|
20025
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20225
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-object-as-default-parameter.md
|
|
20026
20226
|
*/
|
|
20027
20227
|
"unicorn/no-object-as-default-parameter"?: Linter.RuleEntry<[]>;
|
|
20028
20228
|
/**
|
|
20029
20229
|
* Disallow `process.exit()`.
|
|
20030
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20230
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-process-exit.md
|
|
20031
20231
|
*/
|
|
20032
20232
|
"unicorn/no-process-exit"?: Linter.RuleEntry<[]>;
|
|
20033
20233
|
/**
|
|
20034
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20234
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#no-reduce
|
|
20035
20235
|
* @deprecated
|
|
20036
20236
|
*/
|
|
20037
20237
|
"unicorn/no-reduce"?: Linter.RuleEntry<[]>;
|
|
20038
20238
|
/**
|
|
20039
20239
|
* Disallow passing single-element arrays to `Promise` methods.
|
|
20040
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20240
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-single-promise-in-promise-methods.md
|
|
20041
20241
|
*/
|
|
20042
20242
|
"unicorn/no-single-promise-in-promise-methods"?: Linter.RuleEntry<[]>;
|
|
20043
20243
|
/**
|
|
20044
20244
|
* Disallow classes that only have static members.
|
|
20045
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20245
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-static-only-class.md
|
|
20046
20246
|
*/
|
|
20047
20247
|
"unicorn/no-static-only-class"?: Linter.RuleEntry<[]>;
|
|
20048
20248
|
/**
|
|
20049
20249
|
* Disallow `then` property.
|
|
20050
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20250
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-thenable.md
|
|
20051
20251
|
*/
|
|
20052
20252
|
"unicorn/no-thenable"?: Linter.RuleEntry<[]>;
|
|
20053
20253
|
/**
|
|
20054
20254
|
* Disallow assigning `this` to a variable.
|
|
20055
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20255
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-this-assignment.md
|
|
20056
20256
|
*/
|
|
20057
20257
|
"unicorn/no-this-assignment"?: Linter.RuleEntry<[]>;
|
|
20058
20258
|
/**
|
|
20059
20259
|
* Disallow comparing `undefined` using `typeof`.
|
|
20060
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20260
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-typeof-undefined.md
|
|
20061
20261
|
*/
|
|
20062
20262
|
"unicorn/no-typeof-undefined"?: Linter.RuleEntry<UnicornNoTypeofUndefined>;
|
|
20063
20263
|
/**
|
|
20064
20264
|
* Disallow awaiting non-promise values.
|
|
20065
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20265
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-unnecessary-await.md
|
|
20066
20266
|
*/
|
|
20067
20267
|
"unicorn/no-unnecessary-await"?: Linter.RuleEntry<[]>;
|
|
20068
20268
|
/**
|
|
20069
20269
|
* Enforce the use of built-in methods instead of unnecessary polyfills.
|
|
20070
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20270
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-unnecessary-polyfills.md
|
|
20071
20271
|
*/
|
|
20072
20272
|
"unicorn/no-unnecessary-polyfills"?: Linter.RuleEntry<UnicornNoUnnecessaryPolyfills>;
|
|
20073
20273
|
/**
|
|
20074
20274
|
* Disallow unreadable array destructuring.
|
|
20075
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20275
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-unreadable-array-destructuring.md
|
|
20076
20276
|
*/
|
|
20077
20277
|
"unicorn/no-unreadable-array-destructuring"?: Linter.RuleEntry<[]>;
|
|
20078
20278
|
/**
|
|
20079
20279
|
* Disallow unreadable IIFEs.
|
|
20080
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20280
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-unreadable-iife.md
|
|
20081
20281
|
*/
|
|
20082
20282
|
"unicorn/no-unreadable-iife"?: Linter.RuleEntry<[]>;
|
|
20083
20283
|
/**
|
|
20084
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20284
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#no-unsafe-regex
|
|
20085
20285
|
* @deprecated
|
|
20086
20286
|
*/
|
|
20087
20287
|
"unicorn/no-unsafe-regex"?: Linter.RuleEntry<[]>;
|
|
20088
20288
|
/**
|
|
20089
20289
|
* Disallow unused object properties.
|
|
20090
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20290
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-unused-properties.md
|
|
20091
20291
|
*/
|
|
20092
20292
|
"unicorn/no-unused-properties"?: Linter.RuleEntry<[]>;
|
|
20093
20293
|
/**
|
|
20094
20294
|
* Disallow useless fallback when spreading in object literals.
|
|
20095
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20295
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-useless-fallback-in-spread.md
|
|
20096
20296
|
*/
|
|
20097
20297
|
"unicorn/no-useless-fallback-in-spread"?: Linter.RuleEntry<[]>;
|
|
20098
20298
|
/**
|
|
20099
20299
|
* Disallow useless array length check.
|
|
20100
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20300
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-useless-length-check.md
|
|
20101
20301
|
*/
|
|
20102
20302
|
"unicorn/no-useless-length-check"?: Linter.RuleEntry<[]>;
|
|
20103
20303
|
/**
|
|
20104
20304
|
* Disallow returning/yielding `Promise.resolve/reject()` in async functions or promise callbacks
|
|
20105
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20305
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-useless-promise-resolve-reject.md
|
|
20106
20306
|
*/
|
|
20107
20307
|
"unicorn/no-useless-promise-resolve-reject"?: Linter.RuleEntry<[]>;
|
|
20108
20308
|
/**
|
|
20109
20309
|
* Disallow unnecessary spread.
|
|
20110
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20310
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-useless-spread.md
|
|
20111
20311
|
*/
|
|
20112
20312
|
"unicorn/no-useless-spread"?: Linter.RuleEntry<[]>;
|
|
20113
20313
|
/**
|
|
20114
20314
|
* Disallow useless case in switch statements.
|
|
20115
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20315
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-useless-switch-case.md
|
|
20116
20316
|
*/
|
|
20117
20317
|
"unicorn/no-useless-switch-case"?: Linter.RuleEntry<[]>;
|
|
20118
20318
|
/**
|
|
20119
20319
|
* Disallow useless `undefined`.
|
|
20120
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20320
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-useless-undefined.md
|
|
20121
20321
|
*/
|
|
20122
20322
|
"unicorn/no-useless-undefined"?: Linter.RuleEntry<UnicornNoUselessUndefined>;
|
|
20123
20323
|
/**
|
|
20124
20324
|
* Disallow number literals with zero fractions or dangling dots.
|
|
20125
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20325
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/no-zero-fractions.md
|
|
20126
20326
|
*/
|
|
20127
20327
|
"unicorn/no-zero-fractions"?: Linter.RuleEntry<[]>;
|
|
20128
20328
|
/**
|
|
20129
20329
|
* Enforce proper case for numeric literals.
|
|
20130
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20330
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/number-literal-case.md
|
|
20131
20331
|
*/
|
|
20132
20332
|
"unicorn/number-literal-case"?: Linter.RuleEntry<[]>;
|
|
20133
20333
|
/**
|
|
20134
20334
|
* Enforce the style of numeric separators by correctly grouping digits.
|
|
20135
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20335
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/numeric-separators-style.md
|
|
20136
20336
|
*/
|
|
20137
20337
|
"unicorn/numeric-separators-style"?: Linter.RuleEntry<UnicornNumericSeparatorsStyle>;
|
|
20138
20338
|
/**
|
|
20139
20339
|
* Prefer `.addEventListener()` and `.removeEventListener()` over `on`-functions.
|
|
20140
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20340
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-add-event-listener.md
|
|
20141
20341
|
*/
|
|
20142
20342
|
"unicorn/prefer-add-event-listener"?: Linter.RuleEntry<UnicornPreferAddEventListener>;
|
|
20143
20343
|
/**
|
|
20144
20344
|
* Prefer `.find(…)` and `.findLast(…)` over the first or last element from `.filter(…)`.
|
|
20145
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20345
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-array-find.md
|
|
20146
20346
|
*/
|
|
20147
20347
|
"unicorn/prefer-array-find"?: Linter.RuleEntry<UnicornPreferArrayFind>;
|
|
20148
20348
|
/**
|
|
20149
20349
|
* Prefer `Array#flat()` over legacy techniques to flatten arrays.
|
|
20150
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20350
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-array-flat.md
|
|
20151
20351
|
*/
|
|
20152
20352
|
"unicorn/prefer-array-flat"?: Linter.RuleEntry<UnicornPreferArrayFlat>;
|
|
20153
20353
|
/**
|
|
20154
20354
|
* Prefer `.flatMap(…)` over `.map(…).flat()`.
|
|
20155
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20355
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-array-flat-map.md
|
|
20156
20356
|
*/
|
|
20157
20357
|
"unicorn/prefer-array-flat-map"?: Linter.RuleEntry<[]>;
|
|
20158
20358
|
/**
|
|
20159
20359
|
* Prefer `Array#{indexOf,lastIndexOf}()` over `Array#{findIndex,findLastIndex}()` when looking for the index of an item.
|
|
20160
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20360
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-array-index-of.md
|
|
20161
20361
|
*/
|
|
20162
20362
|
"unicorn/prefer-array-index-of"?: Linter.RuleEntry<[]>;
|
|
20163
20363
|
/**
|
|
20164
20364
|
* Prefer `.some(…)` over `.filter(…).length` check and `.{find,findLast,findIndex,findLastIndex}(…)`.
|
|
20165
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20365
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-array-some.md
|
|
20166
20366
|
*/
|
|
20167
20367
|
"unicorn/prefer-array-some"?: Linter.RuleEntry<[]>;
|
|
20168
20368
|
/**
|
|
20169
20369
|
* Prefer `.at()` method for index access and `String#charAt()`.
|
|
20170
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20370
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-at.md
|
|
20171
20371
|
*/
|
|
20172
20372
|
"unicorn/prefer-at"?: Linter.RuleEntry<UnicornPreferAt>;
|
|
20173
20373
|
/**
|
|
20174
20374
|
* Prefer `Blob#arrayBuffer()` over `FileReader#readAsArrayBuffer(…)` and `Blob#text()` over `FileReader#readAsText(…)`.
|
|
20175
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20375
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-blob-reading-methods.md
|
|
20176
20376
|
*/
|
|
20177
20377
|
"unicorn/prefer-blob-reading-methods"?: Linter.RuleEntry<[]>;
|
|
20178
20378
|
/**
|
|
20179
20379
|
* Prefer `String#codePointAt(…)` over `String#charCodeAt(…)` and `String.fromCodePoint(…)` over `String.fromCharCode(…)`.
|
|
20180
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20380
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-code-point.md
|
|
20181
20381
|
*/
|
|
20182
20382
|
"unicorn/prefer-code-point"?: Linter.RuleEntry<[]>;
|
|
20183
20383
|
/**
|
|
20184
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20384
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-dataset
|
|
20185
20385
|
* @deprecated
|
|
20186
20386
|
*/
|
|
20187
20387
|
"unicorn/prefer-dataset"?: Linter.RuleEntry<[]>;
|
|
20188
20388
|
/**
|
|
20189
20389
|
* Prefer `Date.now()` to get the number of milliseconds since the Unix Epoch.
|
|
20190
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20390
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-date-now.md
|
|
20191
20391
|
*/
|
|
20192
20392
|
"unicorn/prefer-date-now"?: Linter.RuleEntry<[]>;
|
|
20193
20393
|
/**
|
|
20194
20394
|
* Prefer default parameters over reassignment.
|
|
20195
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20395
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-default-parameters.md
|
|
20196
20396
|
*/
|
|
20197
20397
|
"unicorn/prefer-default-parameters"?: Linter.RuleEntry<[]>;
|
|
20198
20398
|
/**
|
|
20199
20399
|
* Prefer `Node#append()` over `Node#appendChild()`.
|
|
20200
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20400
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-dom-node-append.md
|
|
20201
20401
|
*/
|
|
20202
20402
|
"unicorn/prefer-dom-node-append"?: Linter.RuleEntry<[]>;
|
|
20203
20403
|
/**
|
|
20204
20404
|
* Prefer using `.dataset` on DOM elements over calling attribute methods.
|
|
20205
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20405
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-dom-node-dataset.md
|
|
20206
20406
|
*/
|
|
20207
20407
|
"unicorn/prefer-dom-node-dataset"?: Linter.RuleEntry<[]>;
|
|
20208
20408
|
/**
|
|
20209
20409
|
* Prefer `childNode.remove()` over `parentNode.removeChild(childNode)`.
|
|
20210
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20410
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-dom-node-remove.md
|
|
20211
20411
|
*/
|
|
20212
20412
|
"unicorn/prefer-dom-node-remove"?: Linter.RuleEntry<[]>;
|
|
20213
20413
|
/**
|
|
20214
20414
|
* Prefer `.textContent` over `.innerText`.
|
|
20215
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20415
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-dom-node-text-content.md
|
|
20216
20416
|
*/
|
|
20217
20417
|
"unicorn/prefer-dom-node-text-content"?: Linter.RuleEntry<[]>;
|
|
20218
20418
|
/**
|
|
20219
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20419
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-event-key
|
|
20220
20420
|
* @deprecated
|
|
20221
20421
|
*/
|
|
20222
20422
|
"unicorn/prefer-event-key"?: Linter.RuleEntry<[]>;
|
|
20223
20423
|
/**
|
|
20224
20424
|
* Prefer `EventTarget` over `EventEmitter`.
|
|
20225
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20425
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-event-target.md
|
|
20226
20426
|
*/
|
|
20227
20427
|
"unicorn/prefer-event-target"?: Linter.RuleEntry<[]>;
|
|
20228
20428
|
/**
|
|
20229
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20429
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-exponentiation-operator
|
|
20230
20430
|
* @deprecated
|
|
20231
20431
|
*/
|
|
20232
20432
|
"unicorn/prefer-exponentiation-operator"?: Linter.RuleEntry<[]>;
|
|
20233
20433
|
/**
|
|
20234
20434
|
* Prefer `export…from` when re-exporting.
|
|
20235
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20435
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-export-from.md
|
|
20236
20436
|
*/
|
|
20237
20437
|
"unicorn/prefer-export-from"?: Linter.RuleEntry<UnicornPreferExportFrom>;
|
|
20238
20438
|
/**
|
|
20239
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20439
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-flat-map
|
|
20240
20440
|
* @deprecated
|
|
20241
20441
|
*/
|
|
20242
20442
|
"unicorn/prefer-flat-map"?: Linter.RuleEntry<[]>;
|
|
20243
20443
|
/**
|
|
20244
20444
|
* Prefer `.includes()` over `.indexOf()`, `.lastIndexOf()`, and `Array#some()` when checking for existence or non-existence.
|
|
20245
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20445
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-includes.md
|
|
20246
20446
|
*/
|
|
20247
20447
|
"unicorn/prefer-includes"?: Linter.RuleEntry<[]>;
|
|
20248
20448
|
/**
|
|
20249
20449
|
* Prefer reading a JSON file as a buffer.
|
|
20250
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20450
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-json-parse-buffer.md
|
|
20251
20451
|
*/
|
|
20252
20452
|
"unicorn/prefer-json-parse-buffer"?: Linter.RuleEntry<[]>;
|
|
20253
20453
|
/**
|
|
20254
20454
|
* Prefer `KeyboardEvent#key` over `KeyboardEvent#keyCode`.
|
|
20255
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20455
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-keyboard-event-key.md
|
|
20256
20456
|
*/
|
|
20257
20457
|
"unicorn/prefer-keyboard-event-key"?: Linter.RuleEntry<[]>;
|
|
20258
20458
|
/**
|
|
20259
20459
|
* Prefer using a logical operator over a ternary.
|
|
20260
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20460
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-logical-operator-over-ternary.md
|
|
20261
20461
|
*/
|
|
20262
20462
|
"unicorn/prefer-logical-operator-over-ternary"?: Linter.RuleEntry<[]>;
|
|
20263
20463
|
/**
|
|
20264
20464
|
* Enforce the use of `Math.trunc` instead of bitwise operators.
|
|
20265
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20465
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-math-trunc.md
|
|
20266
20466
|
*/
|
|
20267
20467
|
"unicorn/prefer-math-trunc"?: Linter.RuleEntry<[]>;
|
|
20268
20468
|
/**
|
|
20269
20469
|
* Prefer `.before()` over `.insertBefore()`, `.replaceWith()` over `.replaceChild()`, prefer one of `.before()`, `.after()`, `.append()` or `.prepend()` over `insertAdjacentText()` and `insertAdjacentElement()`.
|
|
20270
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20470
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-modern-dom-apis.md
|
|
20271
20471
|
*/
|
|
20272
20472
|
"unicorn/prefer-modern-dom-apis"?: Linter.RuleEntry<[]>;
|
|
20273
20473
|
/**
|
|
20274
20474
|
* Prefer modern `Math` APIs over legacy patterns.
|
|
20275
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20475
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-modern-math-apis.md
|
|
20276
20476
|
*/
|
|
20277
20477
|
"unicorn/prefer-modern-math-apis"?: Linter.RuleEntry<[]>;
|
|
20278
20478
|
/**
|
|
20279
20479
|
* Prefer JavaScript modules (ESM) over CommonJS.
|
|
20280
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20480
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-module.md
|
|
20281
20481
|
*/
|
|
20282
20482
|
"unicorn/prefer-module"?: Linter.RuleEntry<[]>;
|
|
20283
20483
|
/**
|
|
20284
20484
|
* Prefer using `String`, `Number`, `BigInt`, `Boolean`, and `Symbol` directly.
|
|
20285
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20485
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-native-coercion-functions.md
|
|
20286
20486
|
*/
|
|
20287
20487
|
"unicorn/prefer-native-coercion-functions"?: Linter.RuleEntry<[]>;
|
|
20288
20488
|
/**
|
|
20289
20489
|
* Prefer negative index over `.length - index` when possible.
|
|
20290
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20490
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-negative-index.md
|
|
20291
20491
|
*/
|
|
20292
20492
|
"unicorn/prefer-negative-index"?: Linter.RuleEntry<[]>;
|
|
20293
20493
|
/**
|
|
20294
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20494
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-node-append
|
|
20295
20495
|
* @deprecated
|
|
20296
20496
|
*/
|
|
20297
20497
|
"unicorn/prefer-node-append"?: Linter.RuleEntry<[]>;
|
|
20298
20498
|
/**
|
|
20299
20499
|
* Prefer using the `node:` protocol when importing Node.js builtin modules.
|
|
20300
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20500
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-node-protocol.md
|
|
20301
20501
|
*/
|
|
20302
20502
|
"unicorn/prefer-node-protocol"?: Linter.RuleEntry<[]>;
|
|
20303
20503
|
/**
|
|
20304
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20504
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-node-remove
|
|
20305
20505
|
* @deprecated
|
|
20306
20506
|
*/
|
|
20307
20507
|
"unicorn/prefer-node-remove"?: Linter.RuleEntry<[]>;
|
|
20308
20508
|
/**
|
|
20309
20509
|
* Prefer `Number` static properties over global ones.
|
|
20310
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20510
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-number-properties.md
|
|
20311
20511
|
*/
|
|
20312
20512
|
"unicorn/prefer-number-properties"?: Linter.RuleEntry<UnicornPreferNumberProperties>;
|
|
20313
20513
|
/**
|
|
20314
20514
|
* Prefer using `Object.fromEntries(…)` to transform a list of key-value pairs into an object.
|
|
20315
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20515
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-object-from-entries.md
|
|
20316
20516
|
*/
|
|
20317
20517
|
"unicorn/prefer-object-from-entries"?: Linter.RuleEntry<UnicornPreferObjectFromEntries>;
|
|
20318
20518
|
/**
|
|
20319
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20519
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-object-has-own
|
|
20320
20520
|
* @deprecated
|
|
20321
20521
|
*/
|
|
20322
20522
|
"unicorn/prefer-object-has-own"?: Linter.RuleEntry<[]>;
|
|
20323
20523
|
/**
|
|
20324
20524
|
* Prefer omitting the `catch` binding parameter.
|
|
20325
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20525
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-optional-catch-binding.md
|
|
20326
20526
|
*/
|
|
20327
20527
|
"unicorn/prefer-optional-catch-binding"?: Linter.RuleEntry<[]>;
|
|
20328
20528
|
/**
|
|
20329
20529
|
* Prefer borrowing methods from the prototype instead of the instance.
|
|
20330
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20530
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-prototype-methods.md
|
|
20331
20531
|
*/
|
|
20332
20532
|
"unicorn/prefer-prototype-methods"?: Linter.RuleEntry<[]>;
|
|
20333
20533
|
/**
|
|
20334
20534
|
* Prefer `.querySelector()` over `.getElementById()`, `.querySelectorAll()` over `.getElementsByClassName()` and `.getElementsByTagName()`.
|
|
20335
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20535
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-query-selector.md
|
|
20336
20536
|
*/
|
|
20337
20537
|
"unicorn/prefer-query-selector"?: Linter.RuleEntry<[]>;
|
|
20338
20538
|
/**
|
|
20339
20539
|
* Prefer `Reflect.apply()` over `Function#apply()`.
|
|
20340
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20540
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-reflect-apply.md
|
|
20341
20541
|
*/
|
|
20342
20542
|
"unicorn/prefer-reflect-apply"?: Linter.RuleEntry<[]>;
|
|
20343
20543
|
/**
|
|
20344
20544
|
* Prefer `RegExp#test()` over `String#match()` and `RegExp#exec()`.
|
|
20345
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20545
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-regexp-test.md
|
|
20346
20546
|
*/
|
|
20347
20547
|
"unicorn/prefer-regexp-test"?: Linter.RuleEntry<[]>;
|
|
20348
20548
|
/**
|
|
20349
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20549
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-replace-all
|
|
20350
20550
|
* @deprecated
|
|
20351
20551
|
*/
|
|
20352
20552
|
"unicorn/prefer-replace-all"?: Linter.RuleEntry<[]>;
|
|
20353
20553
|
/**
|
|
20354
20554
|
* Prefer `Set#has()` over `Array#includes()` when checking for existence or non-existence.
|
|
20355
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20555
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-set-has.md
|
|
20356
20556
|
*/
|
|
20357
20557
|
"unicorn/prefer-set-has"?: Linter.RuleEntry<[]>;
|
|
20358
20558
|
/**
|
|
20359
20559
|
* Prefer using `Set#size` instead of `Array#length`.
|
|
20360
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20560
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-set-size.md
|
|
20361
20561
|
*/
|
|
20362
20562
|
"unicorn/prefer-set-size"?: Linter.RuleEntry<[]>;
|
|
20363
20563
|
/**
|
|
20364
20564
|
* Prefer the spread operator over `Array.from(…)`, `Array#concat(…)`, `Array#{slice,toSpliced}()` and `String#split('')`.
|
|
20365
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20565
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-spread.md
|
|
20366
20566
|
*/
|
|
20367
20567
|
"unicorn/prefer-spread"?: Linter.RuleEntry<[]>;
|
|
20368
20568
|
/**
|
|
20369
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20569
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-starts-ends-with
|
|
20370
20570
|
* @deprecated
|
|
20371
20571
|
*/
|
|
20372
20572
|
"unicorn/prefer-starts-ends-with"?: Linter.RuleEntry<[]>;
|
|
20373
20573
|
/**
|
|
20374
20574
|
* Prefer using the `String.raw` tag to avoid escaping `\`.
|
|
20375
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20575
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-string-raw.md
|
|
20376
20576
|
*/
|
|
20377
20577
|
"unicorn/prefer-string-raw"?: Linter.RuleEntry<[]>;
|
|
20378
20578
|
/**
|
|
20379
20579
|
* Prefer `String#replaceAll()` over regex searches with the global flag.
|
|
20380
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20580
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-string-replace-all.md
|
|
20381
20581
|
*/
|
|
20382
20582
|
"unicorn/prefer-string-replace-all"?: Linter.RuleEntry<[]>;
|
|
20383
20583
|
/**
|
|
20384
20584
|
* Prefer `String#slice()` over `String#substr()` and `String#substring()`.
|
|
20385
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20585
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-string-slice.md
|
|
20386
20586
|
*/
|
|
20387
20587
|
"unicorn/prefer-string-slice"?: Linter.RuleEntry<[]>;
|
|
20388
20588
|
/**
|
|
20389
20589
|
* Prefer `String#startsWith()` & `String#endsWith()` over `RegExp#test()`.
|
|
20390
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20590
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-string-starts-ends-with.md
|
|
20391
20591
|
*/
|
|
20392
20592
|
"unicorn/prefer-string-starts-ends-with"?: Linter.RuleEntry<[]>;
|
|
20393
20593
|
/**
|
|
20394
20594
|
* Prefer `String#trimStart()` / `String#trimEnd()` over `String#trimLeft()` / `String#trimRight()`.
|
|
20395
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20595
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-string-trim-start-end.md
|
|
20396
20596
|
*/
|
|
20397
20597
|
"unicorn/prefer-string-trim-start-end"?: Linter.RuleEntry<[]>;
|
|
20398
20598
|
/**
|
|
20399
20599
|
* Prefer using `structuredClone` to create a deep clone.
|
|
20400
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20600
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-structured-clone.md
|
|
20401
20601
|
*/
|
|
20402
20602
|
"unicorn/prefer-structured-clone"?: Linter.RuleEntry<UnicornPreferStructuredClone>;
|
|
20403
20603
|
/**
|
|
20404
20604
|
* Prefer `switch` over multiple `else-if`.
|
|
20405
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20605
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-switch.md
|
|
20406
20606
|
*/
|
|
20407
20607
|
"unicorn/prefer-switch"?: Linter.RuleEntry<UnicornPreferSwitch>;
|
|
20408
20608
|
/**
|
|
20409
20609
|
* Prefer ternary expressions over simple `if-else` statements.
|
|
20410
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20610
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-ternary.md
|
|
20411
20611
|
*/
|
|
20412
20612
|
"unicorn/prefer-ternary"?: Linter.RuleEntry<UnicornPreferTernary>;
|
|
20413
20613
|
/**
|
|
20414
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20614
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-text-content
|
|
20415
20615
|
* @deprecated
|
|
20416
20616
|
*/
|
|
20417
20617
|
"unicorn/prefer-text-content"?: Linter.RuleEntry<[]>;
|
|
20418
20618
|
/**
|
|
20419
20619
|
* Prefer top-level await over top-level promises and async function calls.
|
|
20420
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20620
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-top-level-await.md
|
|
20421
20621
|
*/
|
|
20422
20622
|
"unicorn/prefer-top-level-await"?: Linter.RuleEntry<[]>;
|
|
20423
20623
|
/**
|
|
20424
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20624
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#prefer-trim-start-end
|
|
20425
20625
|
* @deprecated
|
|
20426
20626
|
*/
|
|
20427
20627
|
"unicorn/prefer-trim-start-end"?: Linter.RuleEntry<[]>;
|
|
20428
20628
|
/**
|
|
20429
20629
|
* Enforce throwing `TypeError` in type checking conditions.
|
|
20430
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20630
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prefer-type-error.md
|
|
20431
20631
|
*/
|
|
20432
20632
|
"unicorn/prefer-type-error"?: Linter.RuleEntry<[]>;
|
|
20433
20633
|
/**
|
|
20434
20634
|
* Prevent abbreviations.
|
|
20435
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20635
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/prevent-abbreviations.md
|
|
20436
20636
|
*/
|
|
20437
20637
|
"unicorn/prevent-abbreviations"?: Linter.RuleEntry<UnicornPreventAbbreviations>;
|
|
20438
20638
|
/**
|
|
20439
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20639
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/deprecated-rules.md#regex-shorthand
|
|
20440
20640
|
* @deprecated
|
|
20441
20641
|
*/
|
|
20442
20642
|
"unicorn/regex-shorthand"?: Linter.RuleEntry<[]>;
|
|
20443
20643
|
/**
|
|
20444
20644
|
* Enforce consistent relative URL style.
|
|
20445
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20645
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/relative-url-style.md
|
|
20446
20646
|
*/
|
|
20447
20647
|
"unicorn/relative-url-style"?: Linter.RuleEntry<UnicornRelativeUrlStyle>;
|
|
20448
20648
|
/**
|
|
20449
20649
|
* Enforce using the separator argument with `Array#join()`.
|
|
20450
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20650
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/require-array-join-separator.md
|
|
20451
20651
|
*/
|
|
20452
20652
|
"unicorn/require-array-join-separator"?: Linter.RuleEntry<[]>;
|
|
20453
20653
|
/**
|
|
20454
20654
|
* Enforce using the digits argument with `Number#toFixed()`.
|
|
20455
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20655
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/require-number-to-fixed-digits-argument.md
|
|
20456
20656
|
*/
|
|
20457
20657
|
"unicorn/require-number-to-fixed-digits-argument"?: Linter.RuleEntry<[]>;
|
|
20458
20658
|
/**
|
|
20459
20659
|
* Enforce using the `targetOrigin` argument with `window.postMessage()`.
|
|
20460
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20660
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/require-post-message-target-origin.md
|
|
20461
20661
|
*/
|
|
20462
20662
|
"unicorn/require-post-message-target-origin"?: Linter.RuleEntry<[]>;
|
|
20463
20663
|
/**
|
|
20464
20664
|
* Enforce better string content.
|
|
20465
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20665
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/string-content.md
|
|
20466
20666
|
*/
|
|
20467
20667
|
"unicorn/string-content"?: Linter.RuleEntry<UnicornStringContent>;
|
|
20468
20668
|
/**
|
|
20469
20669
|
* Enforce consistent brace style for `case` clauses.
|
|
20470
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20670
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/switch-case-braces.md
|
|
20471
20671
|
*/
|
|
20472
20672
|
"unicorn/switch-case-braces"?: Linter.RuleEntry<UnicornSwitchCaseBraces>;
|
|
20473
20673
|
/**
|
|
20474
20674
|
* Fix whitespace-insensitive template indentation.
|
|
20475
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20675
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/template-indent.md
|
|
20476
20676
|
*/
|
|
20477
20677
|
"unicorn/template-indent"?: Linter.RuleEntry<UnicornTemplateIndent>;
|
|
20478
20678
|
/**
|
|
20479
20679
|
* Enforce consistent case for text encoding identifiers.
|
|
20480
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20680
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/text-encoding-identifier-case.md
|
|
20481
20681
|
*/
|
|
20482
20682
|
"unicorn/text-encoding-identifier-case"?: Linter.RuleEntry<[]>;
|
|
20483
20683
|
/**
|
|
20484
20684
|
* Require `new` when creating an error.
|
|
20485
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
20685
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v55.0.0/docs/rules/throw-new-error.md
|
|
20486
20686
|
*/
|
|
20487
20687
|
"unicorn/throw-new-error"?: Linter.RuleEntry<[]>;
|
|
20488
20688
|
}
|