@bfra.me/eslint-config 0.35.2 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +561 -174
- package/lib/index.js +2 -27
- package/package.json +4 -4
- package/src/configs/json-schema.ts +1 -26
- package/src/rules.d.ts +561 -174
package/lib/index.d.ts
CHANGED
|
@@ -2117,7 +2117,7 @@ interface Rules {
|
|
|
2117
2117
|
*/
|
|
2118
2118
|
'jsdoc/check-alignment'?: Linter.RuleEntry<JsdocCheckAlignment>
|
|
2119
2119
|
/**
|
|
2120
|
-
*
|
|
2120
|
+
* @deprecated - Use `getJsdocProcessorPlugin` processor; ensures that (JavaScript) samples within `@example` tags adhere to ESLint rules.
|
|
2121
2121
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-examples.md#repos-sticky-header
|
|
2122
2122
|
*/
|
|
2123
2123
|
'jsdoc/check-examples'?: Linter.RuleEntry<JsdocCheckExamples>
|
|
@@ -2132,7 +2132,7 @@ interface Rules {
|
|
|
2132
2132
|
*/
|
|
2133
2133
|
'jsdoc/check-line-alignment'?: Linter.RuleEntry<JsdocCheckLineAlignment>
|
|
2134
2134
|
/**
|
|
2135
|
-
*
|
|
2135
|
+
* Checks for dupe `@param` names, that nested param names have roots, and that parameter names in function declarations match JSDoc param names.
|
|
2136
2136
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-param-names.md#repos-sticky-header
|
|
2137
2137
|
*/
|
|
2138
2138
|
'jsdoc/check-param-names'?: Linter.RuleEntry<JsdocCheckParamNames>
|
|
@@ -2157,7 +2157,7 @@ interface Rules {
|
|
|
2157
2157
|
*/
|
|
2158
2158
|
'jsdoc/check-template-names'?: Linter.RuleEntry<[]>
|
|
2159
2159
|
/**
|
|
2160
|
-
* Reports invalid
|
|
2160
|
+
* Reports types deemed invalid (customizable and with defaults, for preventing and/or recommending replacements).
|
|
2161
2161
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-types.md#repos-sticky-header
|
|
2162
2162
|
*/
|
|
2163
2163
|
'jsdoc/check-types'?: Linter.RuleEntry<JsdocCheckTypes>
|
|
@@ -2172,12 +2172,17 @@ interface Rules {
|
|
|
2172
2172
|
*/
|
|
2173
2173
|
'jsdoc/convert-to-jsdoc-comments'?: Linter.RuleEntry<JsdocConvertToJsdocComments>
|
|
2174
2174
|
/**
|
|
2175
|
-
*
|
|
2175
|
+
* Checks tags that are expected to be empty (e.g., `@abstract` or `@async`), reporting if they have content
|
|
2176
2176
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/empty-tags.md#repos-sticky-header
|
|
2177
2177
|
*/
|
|
2178
2178
|
'jsdoc/empty-tags'?: Linter.RuleEntry<JsdocEmptyTags>
|
|
2179
2179
|
/**
|
|
2180
|
-
* Reports
|
|
2180
|
+
* Reports use of JSDoc tags in non-tag positions (in the default "typescript" mode).
|
|
2181
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/escape-inline-tags.md#repos-sticky-header
|
|
2182
|
+
*/
|
|
2183
|
+
'jsdoc/escape-inline-tags'?: Linter.RuleEntry<JsdocEscapeInlineTags>
|
|
2184
|
+
/**
|
|
2185
|
+
* Prohibits use of `@implements` on non-constructor functions (to enforce the tag only being used on classes/constructors).
|
|
2181
2186
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/implements-on-classes.md#repos-sticky-header
|
|
2182
2187
|
*/
|
|
2183
2188
|
'jsdoc/implements-on-classes'?: Linter.RuleEntry<JsdocImplementsOnClasses>
|
|
@@ -2207,17 +2212,17 @@ interface Rules {
|
|
|
2207
2212
|
*/
|
|
2208
2213
|
'jsdoc/match-name'?: Linter.RuleEntry<JsdocMatchName>
|
|
2209
2214
|
/**
|
|
2210
|
-
* Controls how and whether
|
|
2215
|
+
* Controls how and whether JSDoc blocks can be expressed as single or multiple line blocks.
|
|
2211
2216
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/multiline-blocks.md#repos-sticky-header
|
|
2212
2217
|
*/
|
|
2213
2218
|
'jsdoc/multiline-blocks'?: Linter.RuleEntry<JsdocMultilineBlocks>
|
|
2214
2219
|
/**
|
|
2215
|
-
* This rule checks for multi-line-style comments which fail to meet the criteria of a
|
|
2220
|
+
* This rule checks for multi-line-style comments which fail to meet the criteria of a JSDoc block.
|
|
2216
2221
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-bad-blocks.md#repos-sticky-header
|
|
2217
2222
|
*/
|
|
2218
2223
|
'jsdoc/no-bad-blocks'?: Linter.RuleEntry<JsdocNoBadBlocks>
|
|
2219
2224
|
/**
|
|
2220
|
-
*
|
|
2225
|
+
* If tags are present, this rule will prevent empty lines in the block description. If no tags are present, this rule will prevent extra empty lines in the block description.
|
|
2221
2226
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-blank-block-descriptions.md#repos-sticky-header
|
|
2222
2227
|
*/
|
|
2223
2228
|
'jsdoc/no-blank-block-descriptions'?: Linter.RuleEntry<[]>
|
|
@@ -2247,22 +2252,37 @@ interface Rules {
|
|
|
2247
2252
|
*/
|
|
2248
2253
|
'jsdoc/no-restricted-syntax'?: Linter.RuleEntry<JsdocNoRestrictedSyntax>
|
|
2249
2254
|
/**
|
|
2250
|
-
* This rule reports types being used on `@param` or `@returns
|
|
2255
|
+
* This rule reports types being used on `@param` or `@returns` (redundant with TypeScript).
|
|
2251
2256
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-types.md#repos-sticky-header
|
|
2252
2257
|
*/
|
|
2253
2258
|
'jsdoc/no-types'?: Linter.RuleEntry<JsdocNoTypes>
|
|
2254
2259
|
/**
|
|
2255
|
-
*
|
|
2260
|
+
* Besides some expected built-in types, prohibits any types not specified as globals or within `@typedef`.
|
|
2256
2261
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-undefined-types.md#repos-sticky-header
|
|
2257
2262
|
*/
|
|
2258
2263
|
'jsdoc/no-undefined-types'?: Linter.RuleEntry<JsdocNoUndefinedTypes>
|
|
2264
|
+
/**
|
|
2265
|
+
* Prefer `@import` tags to inline `import()` statements.
|
|
2266
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/prefer-import-tag.md#repos-sticky-header
|
|
2267
|
+
*/
|
|
2268
|
+
'jsdoc/prefer-import-tag'?: Linter.RuleEntry<JsdocPreferImportTag>
|
|
2269
|
+
/**
|
|
2270
|
+
* Reports use of `any` or `*` type
|
|
2271
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/reject-any-type.md#repos-sticky-header
|
|
2272
|
+
*/
|
|
2273
|
+
'jsdoc/reject-any-type'?: Linter.RuleEntry<[]>
|
|
2274
|
+
/**
|
|
2275
|
+
* Reports use of `Function` type
|
|
2276
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/reject-function-type.md#repos-sticky-header
|
|
2277
|
+
*/
|
|
2278
|
+
'jsdoc/reject-function-type'?: Linter.RuleEntry<[]>
|
|
2259
2279
|
/**
|
|
2260
2280
|
* Requires that each JSDoc line starts with an `*`.
|
|
2261
2281
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-asterisk-prefix.md#repos-sticky-header
|
|
2262
2282
|
*/
|
|
2263
2283
|
'jsdoc/require-asterisk-prefix'?: Linter.RuleEntry<JsdocRequireAsteriskPrefix>
|
|
2264
2284
|
/**
|
|
2265
|
-
* Requires that all functions have a description.
|
|
2285
|
+
* Requires that all functions (and potentially other contexts) have a description.
|
|
2266
2286
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-description.md#repos-sticky-header
|
|
2267
2287
|
*/
|
|
2268
2288
|
'jsdoc/require-description'?: Linter.RuleEntry<JsdocRequireDescription>
|
|
@@ -2272,7 +2292,7 @@ interface Rules {
|
|
|
2272
2292
|
*/
|
|
2273
2293
|
'jsdoc/require-description-complete-sentence'?: Linter.RuleEntry<JsdocRequireDescriptionCompleteSentence>
|
|
2274
2294
|
/**
|
|
2275
|
-
* Requires that all functions have examples.
|
|
2295
|
+
* Requires that all functions (and potentially other contexts) have examples.
|
|
2276
2296
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-example.md#repos-sticky-header
|
|
2277
2297
|
*/
|
|
2278
2298
|
'jsdoc/require-example'?: Linter.RuleEntry<JsdocRequireExample>
|
|
@@ -2282,17 +2302,27 @@ interface Rules {
|
|
|
2282
2302
|
*/
|
|
2283
2303
|
'jsdoc/require-file-overview'?: Linter.RuleEntry<JsdocRequireFileOverview>
|
|
2284
2304
|
/**
|
|
2285
|
-
* Requires a hyphen before the `@param` description.
|
|
2305
|
+
* Requires a hyphen before the `@param` description (and optionally before `@property` descriptions).
|
|
2286
2306
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-hyphen-before-param-description.md#repos-sticky-header
|
|
2287
2307
|
*/
|
|
2288
2308
|
'jsdoc/require-hyphen-before-param-description'?: Linter.RuleEntry<JsdocRequireHyphenBeforeParamDescription>
|
|
2289
2309
|
/**
|
|
2290
|
-
*
|
|
2310
|
+
* Checks for presence of JSDoc comments, on functions and potentially other contexts (optionally limited to exports).
|
|
2291
2311
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-jsdoc.md#repos-sticky-header
|
|
2292
2312
|
*/
|
|
2293
2313
|
'jsdoc/require-jsdoc'?: Linter.RuleEntry<JsdocRequireJsdoc>
|
|
2294
2314
|
/**
|
|
2295
|
-
* Requires
|
|
2315
|
+
* Requires a description for `@next` tags
|
|
2316
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-next-description.md#repos-sticky-header
|
|
2317
|
+
*/
|
|
2318
|
+
'jsdoc/require-next-description'?: Linter.RuleEntry<[]>
|
|
2319
|
+
/**
|
|
2320
|
+
* Requires a type for `@next` tags
|
|
2321
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-next-type.md#repos-sticky-header
|
|
2322
|
+
*/
|
|
2323
|
+
'jsdoc/require-next-type'?: Linter.RuleEntry<[]>
|
|
2324
|
+
/**
|
|
2325
|
+
* Requires that all function parameters are documented with a `@param` tag.
|
|
2296
2326
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param.md#repos-sticky-header
|
|
2297
2327
|
*/
|
|
2298
2328
|
'jsdoc/require-param'?: Linter.RuleEntry<JsdocRequireParam>
|
|
@@ -2302,12 +2332,12 @@ interface Rules {
|
|
|
2302
2332
|
*/
|
|
2303
2333
|
'jsdoc/require-param-description'?: Linter.RuleEntry<JsdocRequireParamDescription>
|
|
2304
2334
|
/**
|
|
2305
|
-
* Requires that all
|
|
2335
|
+
* Requires that all `@param` tags have names.
|
|
2306
2336
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param-name.md#repos-sticky-header
|
|
2307
2337
|
*/
|
|
2308
2338
|
'jsdoc/require-param-name'?: Linter.RuleEntry<JsdocRequireParamName>
|
|
2309
2339
|
/**
|
|
2310
|
-
* Requires that each `@param` tag has a
|
|
2340
|
+
* Requires that each `@param` tag has a type value (in curly brackets).
|
|
2311
2341
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param-type.md#repos-sticky-header
|
|
2312
2342
|
*/
|
|
2313
2343
|
'jsdoc/require-param-type'?: Linter.RuleEntry<JsdocRequireParamType>
|
|
@@ -2322,62 +2352,92 @@ interface Rules {
|
|
|
2322
2352
|
*/
|
|
2323
2353
|
'jsdoc/require-property-description'?: Linter.RuleEntry<[]>
|
|
2324
2354
|
/**
|
|
2325
|
-
* Requires that all
|
|
2355
|
+
* Requires that all `@property` tags have names.
|
|
2326
2356
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-property-name.md#repos-sticky-header
|
|
2327
2357
|
*/
|
|
2328
2358
|
'jsdoc/require-property-name'?: Linter.RuleEntry<[]>
|
|
2329
2359
|
/**
|
|
2330
|
-
* Requires that each `@property` tag has a
|
|
2360
|
+
* Requires that each `@property` tag has a type value (in curly brackets).
|
|
2331
2361
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-property-type.md#repos-sticky-header
|
|
2332
2362
|
*/
|
|
2333
2363
|
'jsdoc/require-property-type'?: Linter.RuleEntry<[]>
|
|
2334
2364
|
/**
|
|
2335
|
-
* Requires that returns are documented
|
|
2365
|
+
* Requires that returns are documented with `@returns`.
|
|
2336
2366
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns.md#repos-sticky-header
|
|
2337
2367
|
*/
|
|
2338
2368
|
'jsdoc/require-returns'?: Linter.RuleEntry<JsdocRequireReturns>
|
|
2339
2369
|
/**
|
|
2340
|
-
* Requires a return statement in function body if a `@returns` tag is specified in
|
|
2370
|
+
* Requires a return statement in function body if a `@returns` tag is specified in JSDoc comment(and reports if multiple `@returns` tags are present).
|
|
2341
2371
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns-check.md#repos-sticky-header
|
|
2342
2372
|
*/
|
|
2343
2373
|
'jsdoc/require-returns-check'?: Linter.RuleEntry<JsdocRequireReturnsCheck>
|
|
2344
2374
|
/**
|
|
2345
|
-
* Requires that the `@returns` tag has a `description` value.
|
|
2375
|
+
* Requires that the `@returns` tag has a `description` value (not including `void`/`undefined` type returns).
|
|
2346
2376
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns-description.md#repos-sticky-header
|
|
2347
2377
|
*/
|
|
2348
2378
|
'jsdoc/require-returns-description'?: Linter.RuleEntry<JsdocRequireReturnsDescription>
|
|
2349
2379
|
/**
|
|
2350
|
-
* Requires that `@returns` tag has
|
|
2380
|
+
* Requires that `@returns` tag has type value (in curly brackets).
|
|
2351
2381
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns-type.md#repos-sticky-header
|
|
2352
2382
|
*/
|
|
2353
2383
|
'jsdoc/require-returns-type'?: Linter.RuleEntry<JsdocRequireReturnsType>
|
|
2354
2384
|
/**
|
|
2355
|
-
* Requires
|
|
2385
|
+
* Requires tags be present, optionally for specific contexts
|
|
2386
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-tags.md#repos-sticky-header
|
|
2387
|
+
*/
|
|
2388
|
+
'jsdoc/require-tags'?: Linter.RuleEntry<JsdocRequireTags>
|
|
2389
|
+
/**
|
|
2390
|
+
* Requires `@template` tags be present when type parameters are used.
|
|
2356
2391
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-template.md#repos-sticky-header
|
|
2357
2392
|
*/
|
|
2358
2393
|
'jsdoc/require-template'?: Linter.RuleEntry<JsdocRequireTemplate>
|
|
2359
2394
|
/**
|
|
2360
|
-
* Requires
|
|
2395
|
+
* Requires a description for `@template` tags
|
|
2396
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-template-description.md#repos-sticky-header
|
|
2397
|
+
*/
|
|
2398
|
+
'jsdoc/require-template-description'?: Linter.RuleEntry<[]>
|
|
2399
|
+
/**
|
|
2400
|
+
* Requires that throw statements are documented with `@throws` tags.
|
|
2361
2401
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-throws.md#repos-sticky-header
|
|
2362
2402
|
*/
|
|
2363
2403
|
'jsdoc/require-throws'?: Linter.RuleEntry<JsdocRequireThrows>
|
|
2364
2404
|
/**
|
|
2365
|
-
* Requires
|
|
2405
|
+
* Requires a description for `@throws` tags
|
|
2406
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-throws-description.md#repos-sticky-header
|
|
2407
|
+
*/
|
|
2408
|
+
'jsdoc/require-throws-description'?: Linter.RuleEntry<[]>
|
|
2409
|
+
/**
|
|
2410
|
+
* Requires a type for `@throws` tags
|
|
2411
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-throws-type.md#repos-sticky-header
|
|
2412
|
+
*/
|
|
2413
|
+
'jsdoc/require-throws-type'?: Linter.RuleEntry<[]>
|
|
2414
|
+
/**
|
|
2415
|
+
* Requires yields are documented with `@yields` tags.
|
|
2366
2416
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-yields.md#repos-sticky-header
|
|
2367
2417
|
*/
|
|
2368
2418
|
'jsdoc/require-yields'?: Linter.RuleEntry<JsdocRequireYields>
|
|
2369
2419
|
/**
|
|
2370
|
-
*
|
|
2420
|
+
* Ensures that if a `@yields` is present that a `yield` (or `yield` with a value) is present in the function body (or that if a `@next` is present that there is a yield with a return value present).
|
|
2371
2421
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-yields-check.md#repos-sticky-header
|
|
2372
2422
|
*/
|
|
2373
2423
|
'jsdoc/require-yields-check'?: Linter.RuleEntry<JsdocRequireYieldsCheck>
|
|
2374
2424
|
/**
|
|
2375
|
-
*
|
|
2425
|
+
* Requires a description for `@yields` tags
|
|
2426
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-yields-description.md#repos-sticky-header
|
|
2427
|
+
*/
|
|
2428
|
+
'jsdoc/require-yields-description'?: Linter.RuleEntry<[]>
|
|
2429
|
+
/**
|
|
2430
|
+
* Requires a type for `@yields` tags
|
|
2431
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-yields-type.md#repos-sticky-header
|
|
2432
|
+
*/
|
|
2433
|
+
'jsdoc/require-yields-type'?: Linter.RuleEntry<[]>
|
|
2434
|
+
/**
|
|
2435
|
+
* Sorts tags by a specified sequence according to tag name, optionally adding line breaks between tag groups.
|
|
2376
2436
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/sort-tags.md#repos-sticky-header
|
|
2377
2437
|
*/
|
|
2378
2438
|
'jsdoc/sort-tags'?: Linter.RuleEntry<JsdocSortTags>
|
|
2379
2439
|
/**
|
|
2380
|
-
* Enforces lines (or no lines) between tags.
|
|
2440
|
+
* Enforces lines (or no lines) before, after, or between tags.
|
|
2381
2441
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/tag-lines.md#repos-sticky-header
|
|
2382
2442
|
*/
|
|
2383
2443
|
'jsdoc/tag-lines'?: Linter.RuleEntry<JsdocTagLines>
|
|
@@ -2386,13 +2446,33 @@ interface Rules {
|
|
|
2386
2446
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/text-escaping.md#repos-sticky-header
|
|
2387
2447
|
*/
|
|
2388
2448
|
'jsdoc/text-escaping'?: Linter.RuleEntry<JsdocTextEscaping>
|
|
2449
|
+
/**
|
|
2450
|
+
* Prefers either function properties or method signatures
|
|
2451
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/ts-method-signature-style.md#repos-sticky-header
|
|
2452
|
+
*/
|
|
2453
|
+
'jsdoc/ts-method-signature-style'?: Linter.RuleEntry<JsdocTsMethodSignatureStyle>
|
|
2454
|
+
/**
|
|
2455
|
+
* Warns against use of the empty object type
|
|
2456
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/ts-no-empty-object-type.md#repos-sticky-header
|
|
2457
|
+
*/
|
|
2458
|
+
'jsdoc/ts-no-empty-object-type'?: Linter.RuleEntry<[]>
|
|
2459
|
+
/**
|
|
2460
|
+
* Catches unnecessary template expressions such as string expressions within a template literal.
|
|
2461
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/ts-no-unnecessary-template-expression.md#repos-sticky-header
|
|
2462
|
+
*/
|
|
2463
|
+
'jsdoc/ts-no-unnecessary-template-expression'?: Linter.RuleEntry<JsdocTsNoUnnecessaryTemplateExpression>
|
|
2464
|
+
/**
|
|
2465
|
+
* Prefers function types over call signatures when there are no other properties.
|
|
2466
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/ts-prefer-function-type.md#repos-sticky-header
|
|
2467
|
+
*/
|
|
2468
|
+
'jsdoc/ts-prefer-function-type'?: Linter.RuleEntry<JsdocTsPreferFunctionType>
|
|
2389
2469
|
/**
|
|
2390
2470
|
* Formats JSDoc type values.
|
|
2391
2471
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/type-formatting.md#repos-sticky-header
|
|
2392
2472
|
*/
|
|
2393
2473
|
'jsdoc/type-formatting'?: Linter.RuleEntry<JsdocTypeFormatting>
|
|
2394
2474
|
/**
|
|
2395
|
-
* Requires all types to be valid JSDoc
|
|
2475
|
+
* Requires all types/namepaths to be valid JSDoc, Closure compiler, or TypeScript types (configurable in settings).
|
|
2396
2476
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/valid-types.md#repos-sticky-header
|
|
2397
2477
|
*/
|
|
2398
2478
|
'jsdoc/valid-types'?: Linter.RuleEntry<JsdocValidTypes>
|
|
@@ -5436,710 +5516,725 @@ interface Rules {
|
|
|
5436
5516
|
'unicode-bom'?: Linter.RuleEntry<UnicodeBom>
|
|
5437
5517
|
/**
|
|
5438
5518
|
* Improve regexes by making them shorter, consistent, and safer.
|
|
5439
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5519
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/better-regex.md
|
|
5440
5520
|
*/
|
|
5441
5521
|
'unicorn/better-regex'?: Linter.RuleEntry<UnicornBetterRegex>
|
|
5442
5522
|
/**
|
|
5443
5523
|
* Enforce a specific parameter name in catch clauses.
|
|
5444
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5524
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/catch-error-name.md
|
|
5445
5525
|
*/
|
|
5446
5526
|
'unicorn/catch-error-name'?: Linter.RuleEntry<UnicornCatchErrorName>
|
|
5447
5527
|
/**
|
|
5448
5528
|
* Enforce consistent assertion style with `node:assert`.
|
|
5449
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5529
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-assert.md
|
|
5450
5530
|
*/
|
|
5451
5531
|
'unicorn/consistent-assert'?: Linter.RuleEntry<[]>
|
|
5452
5532
|
/**
|
|
5453
5533
|
* Prefer passing `Date` directly to the constructor when cloning.
|
|
5454
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5534
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-date-clone.md
|
|
5455
5535
|
*/
|
|
5456
5536
|
'unicorn/consistent-date-clone'?: Linter.RuleEntry<[]>
|
|
5457
5537
|
/**
|
|
5458
5538
|
* Use destructured variables over properties.
|
|
5459
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5539
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-destructuring.md
|
|
5460
5540
|
*/
|
|
5461
5541
|
'unicorn/consistent-destructuring'?: Linter.RuleEntry<[]>
|
|
5462
5542
|
/**
|
|
5463
5543
|
* Prefer consistent types when spreading a ternary in an array literal.
|
|
5464
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5544
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-empty-array-spread.md
|
|
5465
5545
|
*/
|
|
5466
5546
|
'unicorn/consistent-empty-array-spread'?: Linter.RuleEntry<[]>
|
|
5467
5547
|
/**
|
|
5468
5548
|
* Enforce consistent style for element existence checks with `indexOf()`, `lastIndexOf()`, `findIndex()`, and `findLastIndex()`.
|
|
5469
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5549
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-existence-index-check.md
|
|
5470
5550
|
*/
|
|
5471
5551
|
'unicorn/consistent-existence-index-check'?: Linter.RuleEntry<[]>
|
|
5472
5552
|
/**
|
|
5473
5553
|
* Move function definitions to the highest possible scope.
|
|
5474
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5554
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-function-scoping.md
|
|
5475
5555
|
*/
|
|
5476
5556
|
'unicorn/consistent-function-scoping'?: Linter.RuleEntry<UnicornConsistentFunctionScoping>
|
|
5477
5557
|
/**
|
|
5478
5558
|
* Enforce correct `Error` subclassing.
|
|
5479
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5559
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/custom-error-definition.md
|
|
5480
5560
|
*/
|
|
5481
5561
|
'unicorn/custom-error-definition'?: Linter.RuleEntry<[]>
|
|
5482
5562
|
/**
|
|
5483
5563
|
* Enforce no spaces between braces.
|
|
5484
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5564
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/empty-brace-spaces.md
|
|
5485
5565
|
*/
|
|
5486
5566
|
'unicorn/empty-brace-spaces'?: Linter.RuleEntry<[]>
|
|
5487
5567
|
/**
|
|
5488
5568
|
* Enforce passing a `message` value when creating a built-in error.
|
|
5489
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5569
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/error-message.md
|
|
5490
5570
|
*/
|
|
5491
5571
|
'unicorn/error-message'?: Linter.RuleEntry<[]>
|
|
5492
5572
|
/**
|
|
5493
5573
|
* Require escape sequences to use uppercase or lowercase values.
|
|
5494
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5574
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/escape-case.md
|
|
5495
5575
|
*/
|
|
5496
5576
|
'unicorn/escape-case'?: Linter.RuleEntry<UnicornEscapeCase>
|
|
5497
5577
|
/**
|
|
5498
5578
|
* Add expiration conditions to TODO comments.
|
|
5499
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5579
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/expiring-todo-comments.md
|
|
5500
5580
|
*/
|
|
5501
5581
|
'unicorn/expiring-todo-comments'?: Linter.RuleEntry<UnicornExpiringTodoComments>
|
|
5502
5582
|
/**
|
|
5503
5583
|
* Enforce explicitly comparing the `length` or `size` property of a value.
|
|
5504
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5584
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/explicit-length-check.md
|
|
5505
5585
|
*/
|
|
5506
5586
|
'unicorn/explicit-length-check'?: Linter.RuleEntry<UnicornExplicitLengthCheck>
|
|
5507
5587
|
/**
|
|
5508
5588
|
* Enforce a case style for filenames.
|
|
5509
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5589
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/filename-case.md
|
|
5510
5590
|
*/
|
|
5511
5591
|
'unicorn/filename-case'?: Linter.RuleEntry<UnicornFilenameCase>
|
|
5512
5592
|
/**
|
|
5513
5593
|
* Enforce specific import styles per module.
|
|
5514
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5594
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/import-style.md
|
|
5515
5595
|
*/
|
|
5516
5596
|
'unicorn/import-style'?: Linter.RuleEntry<UnicornImportStyle>
|
|
5517
5597
|
/**
|
|
5518
5598
|
* Enforce the use of `new` for all builtins, except `String`, `Number`, `Boolean`, `Symbol` and `BigInt`.
|
|
5519
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5599
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/new-for-builtins.md
|
|
5520
5600
|
*/
|
|
5521
5601
|
'unicorn/new-for-builtins'?: Linter.RuleEntry<[]>
|
|
5522
5602
|
/**
|
|
5523
5603
|
* Enforce specifying rules to disable in `eslint-disable` comments.
|
|
5524
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5604
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-abusive-eslint-disable.md
|
|
5525
5605
|
*/
|
|
5526
5606
|
'unicorn/no-abusive-eslint-disable'?: Linter.RuleEntry<[]>
|
|
5527
5607
|
/**
|
|
5528
5608
|
* Disallow recursive access to `this` within getters and setters.
|
|
5529
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5609
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-accessor-recursion.md
|
|
5530
5610
|
*/
|
|
5531
5611
|
'unicorn/no-accessor-recursion'?: Linter.RuleEntry<[]>
|
|
5532
5612
|
/**
|
|
5533
5613
|
* Disallow anonymous functions and classes as the default export.
|
|
5534
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5614
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-anonymous-default-export.md
|
|
5535
5615
|
*/
|
|
5536
5616
|
'unicorn/no-anonymous-default-export'?: Linter.RuleEntry<[]>
|
|
5537
5617
|
/**
|
|
5538
5618
|
* Prevent passing a function reference directly to iterator methods.
|
|
5539
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5619
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-callback-reference.md
|
|
5540
5620
|
*/
|
|
5541
5621
|
'unicorn/no-array-callback-reference'?: Linter.RuleEntry<[]>
|
|
5542
5622
|
/**
|
|
5543
5623
|
* Prefer `for…of` over the `forEach` method.
|
|
5544
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5624
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-for-each.md
|
|
5545
5625
|
*/
|
|
5546
5626
|
'unicorn/no-array-for-each'?: Linter.RuleEntry<[]>
|
|
5547
5627
|
/**
|
|
5548
5628
|
* Disallow using the `this` argument in array methods.
|
|
5549
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5629
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-method-this-argument.md
|
|
5550
5630
|
*/
|
|
5551
5631
|
'unicorn/no-array-method-this-argument'?: Linter.RuleEntry<[]>
|
|
5552
5632
|
/**
|
|
5553
5633
|
* Replaced by `unicorn/prefer-single-call` which covers more cases.
|
|
5554
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5634
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/deprecated-rules.md#no-array-push-push
|
|
5555
5635
|
* @deprecated
|
|
5556
5636
|
*/
|
|
5557
5637
|
'unicorn/no-array-push-push'?: Linter.RuleEntry<[]>
|
|
5558
5638
|
/**
|
|
5559
5639
|
* Disallow `Array#reduce()` and `Array#reduceRight()`.
|
|
5560
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5640
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-reduce.md
|
|
5561
5641
|
*/
|
|
5562
5642
|
'unicorn/no-array-reduce'?: Linter.RuleEntry<UnicornNoArrayReduce>
|
|
5563
5643
|
/**
|
|
5564
5644
|
* Prefer `Array#toReversed()` over `Array#reverse()`.
|
|
5565
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5645
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-reverse.md
|
|
5566
5646
|
*/
|
|
5567
5647
|
'unicorn/no-array-reverse'?: Linter.RuleEntry<UnicornNoArrayReverse>
|
|
5568
5648
|
/**
|
|
5569
5649
|
* Prefer `Array#toSorted()` over `Array#sort()`.
|
|
5570
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5650
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-sort.md
|
|
5571
5651
|
*/
|
|
5572
5652
|
'unicorn/no-array-sort'?: Linter.RuleEntry<UnicornNoArraySort>
|
|
5573
5653
|
/**
|
|
5574
5654
|
* Disallow member access from await expression.
|
|
5575
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5655
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-await-expression-member.md
|
|
5576
5656
|
*/
|
|
5577
5657
|
'unicorn/no-await-expression-member'?: Linter.RuleEntry<[]>
|
|
5578
5658
|
/**
|
|
5579
5659
|
* Disallow using `await` in `Promise` method parameters.
|
|
5580
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5660
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-await-in-promise-methods.md
|
|
5581
5661
|
*/
|
|
5582
5662
|
'unicorn/no-await-in-promise-methods'?: Linter.RuleEntry<[]>
|
|
5583
5663
|
/**
|
|
5584
5664
|
* Do not use leading/trailing space between `console.log` parameters.
|
|
5585
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5665
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-console-spaces.md
|
|
5586
5666
|
*/
|
|
5587
5667
|
'unicorn/no-console-spaces'?: Linter.RuleEntry<[]>
|
|
5588
5668
|
/**
|
|
5589
5669
|
* Do not use `document.cookie` directly.
|
|
5590
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5670
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-document-cookie.md
|
|
5591
5671
|
*/
|
|
5592
5672
|
'unicorn/no-document-cookie'?: Linter.RuleEntry<[]>
|
|
5593
5673
|
/**
|
|
5594
5674
|
* Disallow empty files.
|
|
5595
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5675
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-empty-file.md
|
|
5596
5676
|
*/
|
|
5597
5677
|
'unicorn/no-empty-file'?: Linter.RuleEntry<[]>
|
|
5598
5678
|
/**
|
|
5599
5679
|
* Do not use a `for` loop that can be replaced with a `for-of` loop.
|
|
5600
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5680
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-for-loop.md
|
|
5601
5681
|
*/
|
|
5602
5682
|
'unicorn/no-for-loop'?: Linter.RuleEntry<[]>
|
|
5603
5683
|
/**
|
|
5604
5684
|
* Enforce the use of Unicode escapes instead of hexadecimal escapes.
|
|
5605
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5685
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-hex-escape.md
|
|
5606
5686
|
*/
|
|
5607
5687
|
'unicorn/no-hex-escape'?: Linter.RuleEntry<[]>
|
|
5688
|
+
/**
|
|
5689
|
+
* Disallow immediate mutation after variable assignment.
|
|
5690
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-immediate-mutation.md
|
|
5691
|
+
*/
|
|
5692
|
+
'unicorn/no-immediate-mutation'?: Linter.RuleEntry<[]>
|
|
5608
5693
|
/**
|
|
5609
5694
|
* Replaced by `unicorn/no-instanceof-builtins` which covers more cases.
|
|
5610
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5695
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/deprecated-rules.md#no-instanceof-array
|
|
5611
5696
|
* @deprecated
|
|
5612
5697
|
*/
|
|
5613
5698
|
'unicorn/no-instanceof-array'?: Linter.RuleEntry<[]>
|
|
5614
5699
|
/**
|
|
5615
5700
|
* Disallow `instanceof` with built-in objects
|
|
5616
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5701
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-instanceof-builtins.md
|
|
5617
5702
|
*/
|
|
5618
5703
|
'unicorn/no-instanceof-builtins'?: Linter.RuleEntry<UnicornNoInstanceofBuiltins>
|
|
5619
5704
|
/**
|
|
5620
5705
|
* Disallow invalid options in `fetch()` and `new Request()`.
|
|
5621
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5706
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-invalid-fetch-options.md
|
|
5622
5707
|
*/
|
|
5623
5708
|
'unicorn/no-invalid-fetch-options'?: Linter.RuleEntry<[]>
|
|
5624
5709
|
/**
|
|
5625
5710
|
* Prevent calling `EventTarget#removeEventListener()` with the result of an expression.
|
|
5626
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5711
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-invalid-remove-event-listener.md
|
|
5627
5712
|
*/
|
|
5628
5713
|
'unicorn/no-invalid-remove-event-listener'?: Linter.RuleEntry<[]>
|
|
5629
5714
|
/**
|
|
5630
5715
|
* Disallow identifiers starting with `new` or `class`.
|
|
5631
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5716
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-keyword-prefix.md
|
|
5632
5717
|
*/
|
|
5633
5718
|
'unicorn/no-keyword-prefix'?: Linter.RuleEntry<UnicornNoKeywordPrefix>
|
|
5634
5719
|
/**
|
|
5635
5720
|
* Replaced by `unicorn/no-unnecessary-slice-end` which covers more cases.
|
|
5636
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5721
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/deprecated-rules.md#no-length-as-slice-end
|
|
5637
5722
|
* @deprecated
|
|
5638
5723
|
*/
|
|
5639
5724
|
'unicorn/no-length-as-slice-end'?: Linter.RuleEntry<[]>
|
|
5640
5725
|
/**
|
|
5641
5726
|
* Disallow `if` statements as the only statement in `if` blocks without `else`.
|
|
5642
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5727
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-lonely-if.md
|
|
5643
5728
|
*/
|
|
5644
5729
|
'unicorn/no-lonely-if'?: Linter.RuleEntry<[]>
|
|
5645
5730
|
/**
|
|
5646
5731
|
* Disallow a magic number as the `depth` argument in `Array#flat(…).`
|
|
5647
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5732
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-magic-array-flat-depth.md
|
|
5648
5733
|
*/
|
|
5649
5734
|
'unicorn/no-magic-array-flat-depth'?: Linter.RuleEntry<[]>
|
|
5650
5735
|
/**
|
|
5651
5736
|
* Disallow named usage of default import and export.
|
|
5652
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5737
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-named-default.md
|
|
5653
5738
|
*/
|
|
5654
5739
|
'unicorn/no-named-default'?: Linter.RuleEntry<[]>
|
|
5655
5740
|
/**
|
|
5656
5741
|
* Disallow negated conditions.
|
|
5657
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5742
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-negated-condition.md
|
|
5658
5743
|
*/
|
|
5659
5744
|
'unicorn/no-negated-condition'?: Linter.RuleEntry<[]>
|
|
5660
5745
|
/**
|
|
5661
5746
|
* Disallow negated expression in equality check.
|
|
5662
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5747
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-negation-in-equality-check.md
|
|
5663
5748
|
*/
|
|
5664
5749
|
'unicorn/no-negation-in-equality-check'?: Linter.RuleEntry<[]>
|
|
5665
5750
|
/**
|
|
5666
5751
|
* Disallow nested ternary expressions.
|
|
5667
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5752
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-nested-ternary.md
|
|
5668
5753
|
*/
|
|
5669
5754
|
'unicorn/no-nested-ternary'?: Linter.RuleEntry<[]>
|
|
5670
5755
|
/**
|
|
5671
5756
|
* Disallow `new Array()`.
|
|
5672
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5757
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-new-array.md
|
|
5673
5758
|
*/
|
|
5674
5759
|
'unicorn/no-new-array'?: Linter.RuleEntry<[]>
|
|
5675
5760
|
/**
|
|
5676
5761
|
* Enforce the use of `Buffer.from()` and `Buffer.alloc()` instead of the deprecated `new Buffer()`.
|
|
5677
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5762
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-new-buffer.md
|
|
5678
5763
|
*/
|
|
5679
5764
|
'unicorn/no-new-buffer'?: Linter.RuleEntry<[]>
|
|
5680
5765
|
/**
|
|
5681
5766
|
* Disallow the use of the `null` literal.
|
|
5682
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5767
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-null.md
|
|
5683
5768
|
*/
|
|
5684
5769
|
'unicorn/no-null'?: Linter.RuleEntry<UnicornNoNull>
|
|
5685
5770
|
/**
|
|
5686
5771
|
* Disallow the use of objects as default parameters.
|
|
5687
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5772
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-object-as-default-parameter.md
|
|
5688
5773
|
*/
|
|
5689
5774
|
'unicorn/no-object-as-default-parameter'?: Linter.RuleEntry<[]>
|
|
5690
5775
|
/**
|
|
5691
5776
|
* Disallow `process.exit()`.
|
|
5692
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5777
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-process-exit.md
|
|
5693
5778
|
*/
|
|
5694
5779
|
'unicorn/no-process-exit'?: Linter.RuleEntry<[]>
|
|
5695
5780
|
/**
|
|
5696
5781
|
* Disallow passing single-element arrays to `Promise` methods.
|
|
5697
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5782
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-single-promise-in-promise-methods.md
|
|
5698
5783
|
*/
|
|
5699
5784
|
'unicorn/no-single-promise-in-promise-methods'?: Linter.RuleEntry<[]>
|
|
5700
5785
|
/**
|
|
5701
5786
|
* Disallow classes that only have static members.
|
|
5702
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5787
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-static-only-class.md
|
|
5703
5788
|
*/
|
|
5704
5789
|
'unicorn/no-static-only-class'?: Linter.RuleEntry<[]>
|
|
5705
5790
|
/**
|
|
5706
5791
|
* Disallow `then` property.
|
|
5707
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5792
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-thenable.md
|
|
5708
5793
|
*/
|
|
5709
5794
|
'unicorn/no-thenable'?: Linter.RuleEntry<[]>
|
|
5710
5795
|
/**
|
|
5711
5796
|
* Disallow assigning `this` to a variable.
|
|
5712
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5797
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-this-assignment.md
|
|
5713
5798
|
*/
|
|
5714
5799
|
'unicorn/no-this-assignment'?: Linter.RuleEntry<[]>
|
|
5715
5800
|
/**
|
|
5716
5801
|
* Disallow comparing `undefined` using `typeof`.
|
|
5717
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5802
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-typeof-undefined.md
|
|
5718
5803
|
*/
|
|
5719
5804
|
'unicorn/no-typeof-undefined'?: Linter.RuleEntry<UnicornNoTypeofUndefined>
|
|
5720
5805
|
/**
|
|
5721
5806
|
* Disallow using `1` as the `depth` argument of `Array#flat()`.
|
|
5722
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5807
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-array-flat-depth.md
|
|
5723
5808
|
*/
|
|
5724
5809
|
'unicorn/no-unnecessary-array-flat-depth'?: Linter.RuleEntry<[]>
|
|
5725
5810
|
/**
|
|
5726
5811
|
* Disallow using `.length` or `Infinity` as the `deleteCount` or `skipCount` argument of `Array#{splice,toSpliced}()`.
|
|
5727
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5812
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-array-splice-count.md
|
|
5728
5813
|
*/
|
|
5729
5814
|
'unicorn/no-unnecessary-array-splice-count'?: Linter.RuleEntry<[]>
|
|
5730
5815
|
/**
|
|
5731
5816
|
* Disallow awaiting non-promise values.
|
|
5732
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5817
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-await.md
|
|
5733
5818
|
*/
|
|
5734
5819
|
'unicorn/no-unnecessary-await'?: Linter.RuleEntry<[]>
|
|
5735
5820
|
/**
|
|
5736
5821
|
* Enforce the use of built-in methods instead of unnecessary polyfills.
|
|
5737
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5822
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-polyfills.md
|
|
5738
5823
|
*/
|
|
5739
5824
|
'unicorn/no-unnecessary-polyfills'?: Linter.RuleEntry<UnicornNoUnnecessaryPolyfills>
|
|
5740
5825
|
/**
|
|
5741
5826
|
* Disallow using `.length` or `Infinity` as the `end` argument of `{Array,String,TypedArray}#slice()`.
|
|
5742
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5827
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-slice-end.md
|
|
5743
5828
|
*/
|
|
5744
5829
|
'unicorn/no-unnecessary-slice-end'?: Linter.RuleEntry<[]>
|
|
5745
5830
|
/**
|
|
5746
5831
|
* Disallow unreadable array destructuring.
|
|
5747
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5832
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unreadable-array-destructuring.md
|
|
5748
5833
|
*/
|
|
5749
5834
|
'unicorn/no-unreadable-array-destructuring'?: Linter.RuleEntry<[]>
|
|
5750
5835
|
/**
|
|
5751
5836
|
* Disallow unreadable IIFEs.
|
|
5752
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5837
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unreadable-iife.md
|
|
5753
5838
|
*/
|
|
5754
5839
|
'unicorn/no-unreadable-iife'?: Linter.RuleEntry<[]>
|
|
5755
5840
|
/**
|
|
5756
5841
|
* Disallow unused object properties.
|
|
5757
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5842
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unused-properties.md
|
|
5758
5843
|
*/
|
|
5759
5844
|
'unicorn/no-unused-properties'?: Linter.RuleEntry<[]>
|
|
5845
|
+
/**
|
|
5846
|
+
* Disallow useless values or fallbacks in `Set`, `Map`, `WeakSet`, or `WeakMap`.
|
|
5847
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-collection-argument.md
|
|
5848
|
+
*/
|
|
5849
|
+
'unicorn/no-useless-collection-argument'?: Linter.RuleEntry<[]>
|
|
5760
5850
|
/**
|
|
5761
5851
|
* Disallow unnecessary `Error.captureStackTrace(…)`.
|
|
5762
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5852
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-error-capture-stack-trace.md
|
|
5763
5853
|
*/
|
|
5764
5854
|
'unicorn/no-useless-error-capture-stack-trace'?: Linter.RuleEntry<[]>
|
|
5765
5855
|
/**
|
|
5766
5856
|
* Disallow useless fallback when spreading in object literals.
|
|
5767
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5857
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-fallback-in-spread.md
|
|
5768
5858
|
*/
|
|
5769
5859
|
'unicorn/no-useless-fallback-in-spread'?: Linter.RuleEntry<[]>
|
|
5770
5860
|
/**
|
|
5771
5861
|
* Disallow useless array length check.
|
|
5772
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5862
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-length-check.md
|
|
5773
5863
|
*/
|
|
5774
5864
|
'unicorn/no-useless-length-check'?: Linter.RuleEntry<[]>
|
|
5775
5865
|
/**
|
|
5776
5866
|
* Disallow returning/yielding `Promise.resolve/reject()` in async functions or promise callbacks
|
|
5777
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5867
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-promise-resolve-reject.md
|
|
5778
5868
|
*/
|
|
5779
5869
|
'unicorn/no-useless-promise-resolve-reject'?: Linter.RuleEntry<[]>
|
|
5780
5870
|
/**
|
|
5781
5871
|
* Disallow unnecessary spread.
|
|
5782
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5872
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-spread.md
|
|
5783
5873
|
*/
|
|
5784
5874
|
'unicorn/no-useless-spread'?: Linter.RuleEntry<[]>
|
|
5785
5875
|
/**
|
|
5786
5876
|
* Disallow useless case in switch statements.
|
|
5787
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5877
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-switch-case.md
|
|
5788
5878
|
*/
|
|
5789
5879
|
'unicorn/no-useless-switch-case'?: Linter.RuleEntry<[]>
|
|
5790
5880
|
/**
|
|
5791
5881
|
* Disallow useless `undefined`.
|
|
5792
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5882
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-undefined.md
|
|
5793
5883
|
*/
|
|
5794
5884
|
'unicorn/no-useless-undefined'?: Linter.RuleEntry<UnicornNoUselessUndefined>
|
|
5795
5885
|
/**
|
|
5796
5886
|
* Disallow number literals with zero fractions or dangling dots.
|
|
5797
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5887
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-zero-fractions.md
|
|
5798
5888
|
*/
|
|
5799
5889
|
'unicorn/no-zero-fractions'?: Linter.RuleEntry<[]>
|
|
5800
5890
|
/**
|
|
5801
5891
|
* Enforce proper case for numeric literals.
|
|
5802
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5892
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/number-literal-case.md
|
|
5803
5893
|
*/
|
|
5804
5894
|
'unicorn/number-literal-case'?: Linter.RuleEntry<UnicornNumberLiteralCase>
|
|
5805
5895
|
/**
|
|
5806
5896
|
* Enforce the style of numeric separators by correctly grouping digits.
|
|
5807
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5897
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/numeric-separators-style.md
|
|
5808
5898
|
*/
|
|
5809
5899
|
'unicorn/numeric-separators-style'?: Linter.RuleEntry<UnicornNumericSeparatorsStyle>
|
|
5810
5900
|
/**
|
|
5811
5901
|
* Prefer `.addEventListener()` and `.removeEventListener()` over `on`-functions.
|
|
5812
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5902
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-add-event-listener.md
|
|
5813
5903
|
*/
|
|
5814
5904
|
'unicorn/prefer-add-event-listener'?: Linter.RuleEntry<UnicornPreferAddEventListener>
|
|
5815
5905
|
/**
|
|
5816
5906
|
* Prefer `.find(…)` and `.findLast(…)` over the first or last element from `.filter(…)`.
|
|
5817
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5907
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-find.md
|
|
5818
5908
|
*/
|
|
5819
5909
|
'unicorn/prefer-array-find'?: Linter.RuleEntry<UnicornPreferArrayFind>
|
|
5820
5910
|
/**
|
|
5821
5911
|
* Prefer `Array#flat()` over legacy techniques to flatten arrays.
|
|
5822
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5912
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-flat.md
|
|
5823
5913
|
*/
|
|
5824
5914
|
'unicorn/prefer-array-flat'?: Linter.RuleEntry<UnicornPreferArrayFlat>
|
|
5825
5915
|
/**
|
|
5826
5916
|
* Prefer `.flatMap(…)` over `.map(…).flat()`.
|
|
5827
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5917
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-flat-map.md
|
|
5828
5918
|
*/
|
|
5829
5919
|
'unicorn/prefer-array-flat-map'?: Linter.RuleEntry<[]>
|
|
5830
5920
|
/**
|
|
5831
5921
|
* Prefer `Array#{indexOf,lastIndexOf}()` over `Array#{findIndex,findLastIndex}()` when looking for the index of an item.
|
|
5832
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5922
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-index-of.md
|
|
5833
5923
|
*/
|
|
5834
5924
|
'unicorn/prefer-array-index-of'?: Linter.RuleEntry<[]>
|
|
5835
5925
|
/**
|
|
5836
5926
|
* Prefer `.some(…)` over `.filter(…).length` check and `.{find,findLast,findIndex,findLastIndex}(…)`.
|
|
5837
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5927
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-some.md
|
|
5838
5928
|
*/
|
|
5839
5929
|
'unicorn/prefer-array-some'?: Linter.RuleEntry<[]>
|
|
5840
5930
|
/**
|
|
5841
5931
|
* Prefer `.at()` method for index access and `String#charAt()`.
|
|
5842
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5932
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-at.md
|
|
5843
5933
|
*/
|
|
5844
5934
|
'unicorn/prefer-at'?: Linter.RuleEntry<UnicornPreferAt>
|
|
5845
5935
|
/**
|
|
5846
5936
|
* Prefer `BigInt` literals over the constructor.
|
|
5847
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5937
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-bigint-literals.md
|
|
5848
5938
|
*/
|
|
5849
5939
|
'unicorn/prefer-bigint-literals'?: Linter.RuleEntry<[]>
|
|
5850
5940
|
/**
|
|
5851
5941
|
* Prefer `Blob#arrayBuffer()` over `FileReader#readAsArrayBuffer(…)` and `Blob#text()` over `FileReader#readAsText(…)`.
|
|
5852
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5942
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-blob-reading-methods.md
|
|
5853
5943
|
*/
|
|
5854
5944
|
'unicorn/prefer-blob-reading-methods'?: Linter.RuleEntry<[]>
|
|
5855
5945
|
/**
|
|
5856
5946
|
* Prefer class field declarations over `this` assignments in constructors.
|
|
5857
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5947
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-class-fields.md
|
|
5858
5948
|
*/
|
|
5859
5949
|
'unicorn/prefer-class-fields'?: Linter.RuleEntry<[]>
|
|
5860
5950
|
/**
|
|
5861
5951
|
* Prefer using `Element#classList.toggle()` to toggle class names.
|
|
5862
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5952
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-classlist-toggle.md
|
|
5863
5953
|
*/
|
|
5864
5954
|
'unicorn/prefer-classlist-toggle'?: Linter.RuleEntry<[]>
|
|
5865
5955
|
/**
|
|
5866
5956
|
* Prefer `String#codePointAt(…)` over `String#charCodeAt(…)` and `String.fromCodePoint(…)` over `String.fromCharCode(…)`.
|
|
5867
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5957
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-code-point.md
|
|
5868
5958
|
*/
|
|
5869
5959
|
'unicorn/prefer-code-point'?: Linter.RuleEntry<[]>
|
|
5870
5960
|
/**
|
|
5871
5961
|
* Prefer `Date.now()` to get the number of milliseconds since the Unix Epoch.
|
|
5872
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5962
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-date-now.md
|
|
5873
5963
|
*/
|
|
5874
5964
|
'unicorn/prefer-date-now'?: Linter.RuleEntry<[]>
|
|
5875
5965
|
/**
|
|
5876
5966
|
* Prefer default parameters over reassignment.
|
|
5877
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5967
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-default-parameters.md
|
|
5878
5968
|
*/
|
|
5879
5969
|
'unicorn/prefer-default-parameters'?: Linter.RuleEntry<[]>
|
|
5880
5970
|
/**
|
|
5881
5971
|
* Prefer `Node#append()` over `Node#appendChild()`.
|
|
5882
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5972
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-append.md
|
|
5883
5973
|
*/
|
|
5884
5974
|
'unicorn/prefer-dom-node-append'?: Linter.RuleEntry<[]>
|
|
5885
5975
|
/**
|
|
5886
5976
|
* Prefer using `.dataset` on DOM elements over calling attribute methods.
|
|
5887
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5977
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-dataset.md
|
|
5888
5978
|
*/
|
|
5889
5979
|
'unicorn/prefer-dom-node-dataset'?: Linter.RuleEntry<[]>
|
|
5890
5980
|
/**
|
|
5891
5981
|
* Prefer `childNode.remove()` over `parentNode.removeChild(childNode)`.
|
|
5892
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5982
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-remove.md
|
|
5893
5983
|
*/
|
|
5894
5984
|
'unicorn/prefer-dom-node-remove'?: Linter.RuleEntry<[]>
|
|
5895
5985
|
/**
|
|
5896
5986
|
* Prefer `.textContent` over `.innerText`.
|
|
5897
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5987
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-text-content.md
|
|
5898
5988
|
*/
|
|
5899
5989
|
'unicorn/prefer-dom-node-text-content'?: Linter.RuleEntry<[]>
|
|
5900
5990
|
/**
|
|
5901
5991
|
* Prefer `EventTarget` over `EventEmitter`.
|
|
5902
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5992
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-event-target.md
|
|
5903
5993
|
*/
|
|
5904
5994
|
'unicorn/prefer-event-target'?: Linter.RuleEntry<[]>
|
|
5905
5995
|
/**
|
|
5906
5996
|
* Prefer `export…from` when re-exporting.
|
|
5907
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
5997
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-export-from.md
|
|
5908
5998
|
*/
|
|
5909
5999
|
'unicorn/prefer-export-from'?: Linter.RuleEntry<UnicornPreferExportFrom>
|
|
5910
6000
|
/**
|
|
5911
6001
|
* Prefer `globalThis` over `window`, `self`, and `global`.
|
|
5912
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6002
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-global-this.md
|
|
5913
6003
|
*/
|
|
5914
6004
|
'unicorn/prefer-global-this'?: Linter.RuleEntry<[]>
|
|
5915
6005
|
/**
|
|
5916
6006
|
* Prefer `import.meta.{dirname,filename}` over legacy techniques for getting file paths.
|
|
5917
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6007
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-import-meta-properties.md
|
|
5918
6008
|
*/
|
|
5919
6009
|
'unicorn/prefer-import-meta-properties'?: Linter.RuleEntry<[]>
|
|
5920
6010
|
/**
|
|
5921
6011
|
* Prefer `.includes()` over `.indexOf()`, `.lastIndexOf()`, and `Array#some()` when checking for existence or non-existence.
|
|
5922
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6012
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-includes.md
|
|
5923
6013
|
*/
|
|
5924
6014
|
'unicorn/prefer-includes'?: Linter.RuleEntry<[]>
|
|
5925
6015
|
/**
|
|
5926
6016
|
* Prefer reading a JSON file as a buffer.
|
|
5927
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6017
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-json-parse-buffer.md
|
|
5928
6018
|
*/
|
|
5929
6019
|
'unicorn/prefer-json-parse-buffer'?: Linter.RuleEntry<[]>
|
|
5930
6020
|
/**
|
|
5931
6021
|
* Prefer `KeyboardEvent#key` over `KeyboardEvent#keyCode`.
|
|
5932
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6022
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-keyboard-event-key.md
|
|
5933
6023
|
*/
|
|
5934
6024
|
'unicorn/prefer-keyboard-event-key'?: Linter.RuleEntry<[]>
|
|
5935
6025
|
/**
|
|
5936
6026
|
* Prefer using a logical operator over a ternary.
|
|
5937
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6027
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-logical-operator-over-ternary.md
|
|
5938
6028
|
*/
|
|
5939
6029
|
'unicorn/prefer-logical-operator-over-ternary'?: Linter.RuleEntry<[]>
|
|
5940
6030
|
/**
|
|
5941
6031
|
* Prefer `Math.min()` and `Math.max()` over ternaries for simple comparisons.
|
|
5942
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6032
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-math-min-max.md
|
|
5943
6033
|
*/
|
|
5944
6034
|
'unicorn/prefer-math-min-max'?: Linter.RuleEntry<[]>
|
|
5945
6035
|
/**
|
|
5946
6036
|
* Enforce the use of `Math.trunc` instead of bitwise operators.
|
|
5947
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6037
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-math-trunc.md
|
|
5948
6038
|
*/
|
|
5949
6039
|
'unicorn/prefer-math-trunc'?: Linter.RuleEntry<[]>
|
|
5950
6040
|
/**
|
|
5951
6041
|
* Prefer `.before()` over `.insertBefore()`, `.replaceWith()` over `.replaceChild()`, prefer one of `.before()`, `.after()`, `.append()` or `.prepend()` over `insertAdjacentText()` and `insertAdjacentElement()`.
|
|
5952
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6042
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-modern-dom-apis.md
|
|
5953
6043
|
*/
|
|
5954
6044
|
'unicorn/prefer-modern-dom-apis'?: Linter.RuleEntry<[]>
|
|
5955
6045
|
/**
|
|
5956
6046
|
* Prefer modern `Math` APIs over legacy patterns.
|
|
5957
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6047
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-modern-math-apis.md
|
|
5958
6048
|
*/
|
|
5959
6049
|
'unicorn/prefer-modern-math-apis'?: Linter.RuleEntry<[]>
|
|
5960
6050
|
/**
|
|
5961
6051
|
* Prefer JavaScript modules (ESM) over CommonJS.
|
|
5962
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6052
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-module.md
|
|
5963
6053
|
*/
|
|
5964
6054
|
'unicorn/prefer-module'?: Linter.RuleEntry<[]>
|
|
5965
6055
|
/**
|
|
5966
6056
|
* Prefer using `String`, `Number`, `BigInt`, `Boolean`, and `Symbol` directly.
|
|
5967
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6057
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-native-coercion-functions.md
|
|
5968
6058
|
*/
|
|
5969
6059
|
'unicorn/prefer-native-coercion-functions'?: Linter.RuleEntry<[]>
|
|
5970
6060
|
/**
|
|
5971
6061
|
* Prefer negative index over `.length - index` when possible.
|
|
5972
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6062
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-negative-index.md
|
|
5973
6063
|
*/
|
|
5974
6064
|
'unicorn/prefer-negative-index'?: Linter.RuleEntry<[]>
|
|
5975
6065
|
/**
|
|
5976
6066
|
* Prefer using the `node:` protocol when importing Node.js builtin modules.
|
|
5977
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6067
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-node-protocol.md
|
|
5978
6068
|
*/
|
|
5979
6069
|
'unicorn/prefer-node-protocol'?: Linter.RuleEntry<[]>
|
|
5980
6070
|
/**
|
|
5981
6071
|
* Prefer `Number` static properties over global ones.
|
|
5982
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6072
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-number-properties.md
|
|
5983
6073
|
*/
|
|
5984
6074
|
'unicorn/prefer-number-properties'?: Linter.RuleEntry<UnicornPreferNumberProperties>
|
|
5985
6075
|
/**
|
|
5986
6076
|
* Prefer using `Object.fromEntries(…)` to transform a list of key-value pairs into an object.
|
|
5987
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6077
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-object-from-entries.md
|
|
5988
6078
|
*/
|
|
5989
6079
|
'unicorn/prefer-object-from-entries'?: Linter.RuleEntry<UnicornPreferObjectFromEntries>
|
|
5990
6080
|
/**
|
|
5991
6081
|
* Prefer omitting the `catch` binding parameter.
|
|
5992
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6082
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-optional-catch-binding.md
|
|
5993
6083
|
*/
|
|
5994
6084
|
'unicorn/prefer-optional-catch-binding'?: Linter.RuleEntry<[]>
|
|
5995
6085
|
/**
|
|
5996
6086
|
* Prefer borrowing methods from the prototype instead of the instance.
|
|
5997
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6087
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-prototype-methods.md
|
|
5998
6088
|
*/
|
|
5999
6089
|
'unicorn/prefer-prototype-methods'?: Linter.RuleEntry<[]>
|
|
6000
6090
|
/**
|
|
6001
6091
|
* Prefer `.querySelector()` over `.getElementById()`, `.querySelectorAll()` over `.getElementsByClassName()` and `.getElementsByTagName()` and `.getElementsByName()`.
|
|
6002
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6092
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-query-selector.md
|
|
6003
6093
|
*/
|
|
6004
6094
|
'unicorn/prefer-query-selector'?: Linter.RuleEntry<[]>
|
|
6005
6095
|
/**
|
|
6006
6096
|
* Prefer `Reflect.apply()` over `Function#apply()`.
|
|
6007
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6097
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-reflect-apply.md
|
|
6008
6098
|
*/
|
|
6009
6099
|
'unicorn/prefer-reflect-apply'?: Linter.RuleEntry<[]>
|
|
6010
6100
|
/**
|
|
6011
6101
|
* Prefer `RegExp#test()` over `String#match()` and `RegExp#exec()`.
|
|
6012
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6102
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-regexp-test.md
|
|
6013
6103
|
*/
|
|
6014
6104
|
'unicorn/prefer-regexp-test'?: Linter.RuleEntry<[]>
|
|
6105
|
+
/**
|
|
6106
|
+
* Prefer `Response.json()` over `new Response(JSON.stringify())`.
|
|
6107
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-response-static-json.md
|
|
6108
|
+
*/
|
|
6109
|
+
'unicorn/prefer-response-static-json'?: Linter.RuleEntry<[]>
|
|
6015
6110
|
/**
|
|
6016
6111
|
* Prefer `Set#has()` over `Array#includes()` when checking for existence or non-existence.
|
|
6017
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6112
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-set-has.md
|
|
6018
6113
|
*/
|
|
6019
6114
|
'unicorn/prefer-set-has'?: Linter.RuleEntry<[]>
|
|
6020
6115
|
/**
|
|
6021
6116
|
* Prefer using `Set#size` instead of `Array#length`.
|
|
6022
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6117
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-set-size.md
|
|
6023
6118
|
*/
|
|
6024
6119
|
'unicorn/prefer-set-size'?: Linter.RuleEntry<[]>
|
|
6025
6120
|
/**
|
|
6026
6121
|
* Enforce combining multiple `Array#push()`, `Element#classList.{add,remove}()`, and `importScripts()` into one call.
|
|
6027
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6122
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-single-call.md
|
|
6028
6123
|
*/
|
|
6029
6124
|
'unicorn/prefer-single-call'?: Linter.RuleEntry<UnicornPreferSingleCall>
|
|
6030
6125
|
/**
|
|
6031
6126
|
* Prefer the spread operator over `Array.from(…)`, `Array#concat(…)`, `Array#{slice,toSpliced}()` and `String#split('')`.
|
|
6032
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6127
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-spread.md
|
|
6033
6128
|
*/
|
|
6034
6129
|
'unicorn/prefer-spread'?: Linter.RuleEntry<[]>
|
|
6035
6130
|
/**
|
|
6036
6131
|
* Prefer using the `String.raw` tag to avoid escaping `\`.
|
|
6037
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6132
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-raw.md
|
|
6038
6133
|
*/
|
|
6039
6134
|
'unicorn/prefer-string-raw'?: Linter.RuleEntry<[]>
|
|
6040
6135
|
/**
|
|
6041
6136
|
* Prefer `String#replaceAll()` over regex searches with the global flag.
|
|
6042
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6137
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-replace-all.md
|
|
6043
6138
|
*/
|
|
6044
6139
|
'unicorn/prefer-string-replace-all'?: Linter.RuleEntry<[]>
|
|
6045
6140
|
/**
|
|
6046
6141
|
* Prefer `String#slice()` over `String#substr()` and `String#substring()`.
|
|
6047
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6142
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-slice.md
|
|
6048
6143
|
*/
|
|
6049
6144
|
'unicorn/prefer-string-slice'?: Linter.RuleEntry<[]>
|
|
6050
6145
|
/**
|
|
6051
6146
|
* Prefer `String#startsWith()` & `String#endsWith()` over `RegExp#test()`.
|
|
6052
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6147
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-starts-ends-with.md
|
|
6053
6148
|
*/
|
|
6054
6149
|
'unicorn/prefer-string-starts-ends-with'?: Linter.RuleEntry<[]>
|
|
6055
6150
|
/**
|
|
6056
6151
|
* Prefer `String#trimStart()` / `String#trimEnd()` over `String#trimLeft()` / `String#trimRight()`.
|
|
6057
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6152
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-trim-start-end.md
|
|
6058
6153
|
*/
|
|
6059
6154
|
'unicorn/prefer-string-trim-start-end'?: Linter.RuleEntry<[]>
|
|
6060
6155
|
/**
|
|
6061
6156
|
* Prefer using `structuredClone` to create a deep clone.
|
|
6062
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6157
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-structured-clone.md
|
|
6063
6158
|
*/
|
|
6064
6159
|
'unicorn/prefer-structured-clone'?: Linter.RuleEntry<UnicornPreferStructuredClone>
|
|
6065
6160
|
/**
|
|
6066
6161
|
* Prefer `switch` over multiple `else-if`.
|
|
6067
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6162
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-switch.md
|
|
6068
6163
|
*/
|
|
6069
6164
|
'unicorn/prefer-switch'?: Linter.RuleEntry<UnicornPreferSwitch>
|
|
6070
6165
|
/**
|
|
6071
6166
|
* Prefer ternary expressions over simple `if-else` statements.
|
|
6072
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6167
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-ternary.md
|
|
6073
6168
|
*/
|
|
6074
6169
|
'unicorn/prefer-ternary'?: Linter.RuleEntry<UnicornPreferTernary>
|
|
6075
6170
|
/**
|
|
6076
6171
|
* Prefer top-level await over top-level promises and async function calls.
|
|
6077
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6172
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-top-level-await.md
|
|
6078
6173
|
*/
|
|
6079
6174
|
'unicorn/prefer-top-level-await'?: Linter.RuleEntry<[]>
|
|
6080
6175
|
/**
|
|
6081
6176
|
* Enforce throwing `TypeError` in type checking conditions.
|
|
6082
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6177
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-type-error.md
|
|
6083
6178
|
*/
|
|
6084
6179
|
'unicorn/prefer-type-error'?: Linter.RuleEntry<[]>
|
|
6085
6180
|
/**
|
|
6086
6181
|
* Prevent abbreviations.
|
|
6087
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6182
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prevent-abbreviations.md
|
|
6088
6183
|
*/
|
|
6089
6184
|
'unicorn/prevent-abbreviations'?: Linter.RuleEntry<UnicornPreventAbbreviations>
|
|
6090
6185
|
/**
|
|
6091
6186
|
* Enforce consistent relative URL style.
|
|
6092
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6187
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/relative-url-style.md
|
|
6093
6188
|
*/
|
|
6094
6189
|
'unicorn/relative-url-style'?: Linter.RuleEntry<UnicornRelativeUrlStyle>
|
|
6095
6190
|
/**
|
|
6096
6191
|
* Enforce using the separator argument with `Array#join()`.
|
|
6097
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6192
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-array-join-separator.md
|
|
6098
6193
|
*/
|
|
6099
6194
|
'unicorn/require-array-join-separator'?: Linter.RuleEntry<[]>
|
|
6100
6195
|
/**
|
|
6101
6196
|
* Require non-empty module attributes for imports and exports
|
|
6102
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6197
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-module-attributes.md
|
|
6103
6198
|
*/
|
|
6104
6199
|
'unicorn/require-module-attributes'?: Linter.RuleEntry<[]>
|
|
6105
6200
|
/**
|
|
6106
6201
|
* Require non-empty specifier list in import and export statements.
|
|
6107
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6202
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-module-specifiers.md
|
|
6108
6203
|
*/
|
|
6109
6204
|
'unicorn/require-module-specifiers'?: Linter.RuleEntry<[]>
|
|
6110
6205
|
/**
|
|
6111
6206
|
* Enforce using the digits argument with `Number#toFixed()`.
|
|
6112
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6207
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-number-to-fixed-digits-argument.md
|
|
6113
6208
|
*/
|
|
6114
6209
|
'unicorn/require-number-to-fixed-digits-argument'?: Linter.RuleEntry<[]>
|
|
6115
6210
|
/**
|
|
6116
6211
|
* Enforce using the `targetOrigin` argument with `window.postMessage()`.
|
|
6117
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6212
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-post-message-target-origin.md
|
|
6118
6213
|
*/
|
|
6119
6214
|
'unicorn/require-post-message-target-origin'?: Linter.RuleEntry<[]>
|
|
6120
6215
|
/**
|
|
6121
6216
|
* Enforce better string content.
|
|
6122
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6217
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/string-content.md
|
|
6123
6218
|
*/
|
|
6124
6219
|
'unicorn/string-content'?: Linter.RuleEntry<UnicornStringContent>
|
|
6125
6220
|
/**
|
|
6126
6221
|
* Enforce consistent brace style for `case` clauses.
|
|
6127
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6222
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/switch-case-braces.md
|
|
6128
6223
|
*/
|
|
6129
6224
|
'unicorn/switch-case-braces'?: Linter.RuleEntry<UnicornSwitchCaseBraces>
|
|
6130
6225
|
/**
|
|
6131
6226
|
* Fix whitespace-insensitive template indentation.
|
|
6132
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6227
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/template-indent.md
|
|
6133
6228
|
*/
|
|
6134
6229
|
'unicorn/template-indent'?: Linter.RuleEntry<UnicornTemplateIndent>
|
|
6135
6230
|
/**
|
|
6136
6231
|
* Enforce consistent case for text encoding identifiers.
|
|
6137
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6232
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/text-encoding-identifier-case.md
|
|
6138
6233
|
*/
|
|
6139
|
-
'unicorn/text-encoding-identifier-case'?: Linter.RuleEntry<
|
|
6234
|
+
'unicorn/text-encoding-identifier-case'?: Linter.RuleEntry<UnicornTextEncodingIdentifierCase>
|
|
6140
6235
|
/**
|
|
6141
6236
|
* Require `new` when creating an error.
|
|
6142
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6237
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/throw-new-error.md
|
|
6143
6238
|
*/
|
|
6144
6239
|
'unicorn/throw-new-error'?: Linter.RuleEntry<[]>
|
|
6145
6240
|
/**
|
|
@@ -9741,6 +9836,7 @@ type InitDeclarations = ([]|["always"] | []|["never"]|["never", {
|
|
|
9741
9836
|
}])
|
|
9742
9837
|
// ----- jsdoc/check-alignment -----
|
|
9743
9838
|
type JsdocCheckAlignment = []|[{
|
|
9839
|
+
|
|
9744
9840
|
innerIndent?: number
|
|
9745
9841
|
}]
|
|
9746
9842
|
// ----- jsdoc/check-examples -----
|
|
@@ -9767,85 +9863,138 @@ type JsdocCheckExamples = []|[{
|
|
|
9767
9863
|
}]
|
|
9768
9864
|
// ----- jsdoc/check-indentation -----
|
|
9769
9865
|
type JsdocCheckIndentation = []|[{
|
|
9866
|
+
|
|
9770
9867
|
excludeTags?: string[]
|
|
9771
9868
|
}]
|
|
9772
9869
|
// ----- jsdoc/check-line-alignment -----
|
|
9773
9870
|
type JsdocCheckLineAlignment = []|[("always" | "never" | "any")]|[("always" | "never" | "any"), {
|
|
9871
|
+
|
|
9774
9872
|
customSpacings?: {
|
|
9873
|
+
|
|
9775
9874
|
postDelimiter?: number
|
|
9875
|
+
|
|
9776
9876
|
postHyphen?: number
|
|
9877
|
+
|
|
9777
9878
|
postName?: number
|
|
9879
|
+
|
|
9778
9880
|
postTag?: number
|
|
9881
|
+
|
|
9779
9882
|
postType?: number
|
|
9780
9883
|
}
|
|
9884
|
+
|
|
9781
9885
|
disableWrapIndent?: boolean
|
|
9886
|
+
|
|
9782
9887
|
preserveMainDescriptionPostDelimiter?: boolean
|
|
9888
|
+
|
|
9783
9889
|
tags?: string[]
|
|
9890
|
+
|
|
9784
9891
|
wrapIndent?: string
|
|
9785
9892
|
}]
|
|
9786
9893
|
// ----- jsdoc/check-param-names -----
|
|
9787
9894
|
type JsdocCheckParamNames = []|[{
|
|
9895
|
+
|
|
9788
9896
|
allowExtraTrailingParamDocs?: boolean
|
|
9897
|
+
|
|
9789
9898
|
checkDestructured?: boolean
|
|
9899
|
+
|
|
9790
9900
|
checkRestProperty?: boolean
|
|
9901
|
+
|
|
9791
9902
|
checkTypesPattern?: string
|
|
9903
|
+
|
|
9792
9904
|
disableExtraPropertyReporting?: boolean
|
|
9905
|
+
|
|
9793
9906
|
disableMissingParamChecks?: boolean
|
|
9907
|
+
|
|
9794
9908
|
enableFixer?: boolean
|
|
9909
|
+
|
|
9795
9910
|
useDefaultObjectProperties?: boolean
|
|
9796
9911
|
}]
|
|
9797
9912
|
// ----- jsdoc/check-property-names -----
|
|
9798
9913
|
type JsdocCheckPropertyNames = []|[{
|
|
9914
|
+
|
|
9799
9915
|
enableFixer?: boolean
|
|
9800
9916
|
}]
|
|
9801
9917
|
// ----- jsdoc/check-tag-names -----
|
|
9802
9918
|
type JsdocCheckTagNames = []|[{
|
|
9919
|
+
|
|
9803
9920
|
definedTags?: string[]
|
|
9921
|
+
|
|
9804
9922
|
enableFixer?: boolean
|
|
9923
|
+
|
|
9924
|
+
inlineTags?: string[]
|
|
9925
|
+
|
|
9805
9926
|
jsxTags?: boolean
|
|
9927
|
+
|
|
9806
9928
|
typed?: boolean
|
|
9807
9929
|
}]
|
|
9808
9930
|
// ----- jsdoc/check-types -----
|
|
9809
9931
|
type JsdocCheckTypes = []|[{
|
|
9932
|
+
|
|
9810
9933
|
exemptTagContexts?: {
|
|
9934
|
+
|
|
9811
9935
|
tag?: string
|
|
9936
|
+
|
|
9812
9937
|
types?: (boolean | string[])
|
|
9813
9938
|
}[]
|
|
9939
|
+
|
|
9814
9940
|
noDefaults?: boolean
|
|
9941
|
+
|
|
9815
9942
|
unifyParentAndChildTypeChecks?: boolean
|
|
9816
9943
|
}]
|
|
9817
9944
|
// ----- jsdoc/check-values -----
|
|
9818
9945
|
type JsdocCheckValues = []|[{
|
|
9946
|
+
|
|
9819
9947
|
allowedAuthors?: string[]
|
|
9948
|
+
|
|
9820
9949
|
allowedLicenses?: (string[] | boolean)
|
|
9950
|
+
|
|
9821
9951
|
licensePattern?: string
|
|
9952
|
+
|
|
9822
9953
|
numericOnlyVariation?: boolean
|
|
9823
9954
|
}]
|
|
9824
9955
|
// ----- jsdoc/convert-to-jsdoc-comments -----
|
|
9825
9956
|
type JsdocConvertToJsdocComments = []|[{
|
|
9957
|
+
|
|
9826
9958
|
allowedPrefixes?: string[]
|
|
9959
|
+
|
|
9827
9960
|
contexts?: (string | {
|
|
9828
9961
|
context?: string
|
|
9829
9962
|
inlineCommentBlock?: boolean
|
|
9830
9963
|
})[]
|
|
9964
|
+
|
|
9831
9965
|
contextsAfter?: (string | {
|
|
9832
9966
|
context?: string
|
|
9833
9967
|
inlineCommentBlock?: boolean
|
|
9834
9968
|
})[]
|
|
9969
|
+
|
|
9835
9970
|
contextsBeforeAndAfter?: (string | {
|
|
9836
9971
|
context?: string
|
|
9837
9972
|
inlineCommentBlock?: boolean
|
|
9838
9973
|
})[]
|
|
9974
|
+
|
|
9839
9975
|
enableFixer?: boolean
|
|
9976
|
+
|
|
9840
9977
|
enforceJsdocLineStyle?: ("multi" | "single")
|
|
9978
|
+
|
|
9841
9979
|
lineOrBlockStyle?: ("block" | "line" | "both")
|
|
9842
9980
|
}]
|
|
9843
9981
|
// ----- jsdoc/empty-tags -----
|
|
9844
9982
|
type JsdocEmptyTags = []|[{
|
|
9983
|
+
|
|
9845
9984
|
tags?: string[]
|
|
9846
9985
|
}]
|
|
9986
|
+
// ----- jsdoc/escape-inline-tags -----
|
|
9987
|
+
type JsdocEscapeInlineTags = []|[{
|
|
9988
|
+
|
|
9989
|
+
allowedInlineTags?: string[]
|
|
9990
|
+
|
|
9991
|
+
enableFixer?: boolean
|
|
9992
|
+
|
|
9993
|
+
fixType?: ("backticks" | "backslash")
|
|
9994
|
+
}]
|
|
9847
9995
|
// ----- jsdoc/implements-on-classes -----
|
|
9848
9996
|
type JsdocImplementsOnClasses = []|[{
|
|
9997
|
+
|
|
9849
9998
|
contexts?: (string | {
|
|
9850
9999
|
comment?: string
|
|
9851
10000
|
context?: string
|
|
@@ -9853,33 +10002,47 @@ type JsdocImplementsOnClasses = []|[{
|
|
|
9853
10002
|
}]
|
|
9854
10003
|
// ----- jsdoc/informative-docs -----
|
|
9855
10004
|
type JsdocInformativeDocs = []|[{
|
|
10005
|
+
|
|
9856
10006
|
aliases?: {
|
|
9857
10007
|
[k: string]: string[]
|
|
9858
10008
|
}
|
|
10009
|
+
|
|
9859
10010
|
excludedTags?: string[]
|
|
10011
|
+
|
|
9860
10012
|
uselessWords?: string[]
|
|
9861
10013
|
}]
|
|
9862
10014
|
// ----- jsdoc/lines-before-block -----
|
|
9863
10015
|
type JsdocLinesBeforeBlock = []|[{
|
|
10016
|
+
|
|
9864
10017
|
checkBlockStarts?: boolean
|
|
10018
|
+
|
|
9865
10019
|
excludedTags?: string[]
|
|
10020
|
+
|
|
9866
10021
|
ignoreSameLine?: boolean
|
|
10022
|
+
|
|
9867
10023
|
ignoreSingleLines?: boolean
|
|
10024
|
+
|
|
9868
10025
|
lines?: number
|
|
9869
10026
|
}]
|
|
9870
10027
|
// ----- jsdoc/match-description -----
|
|
9871
10028
|
type JsdocMatchDescription = []|[{
|
|
10029
|
+
|
|
9872
10030
|
contexts?: (string | {
|
|
9873
10031
|
comment?: string
|
|
9874
10032
|
context?: string
|
|
9875
10033
|
})[]
|
|
10034
|
+
|
|
9876
10035
|
mainDescription?: (string | boolean | {
|
|
9877
10036
|
match?: (string | boolean)
|
|
9878
10037
|
message?: string
|
|
9879
10038
|
})
|
|
10039
|
+
|
|
9880
10040
|
matchDescription?: string
|
|
10041
|
+
|
|
9881
10042
|
message?: string
|
|
10043
|
+
|
|
9882
10044
|
nonemptyTags?: boolean
|
|
10045
|
+
|
|
9883
10046
|
tags?: {
|
|
9884
10047
|
[k: string]: (string | true | {
|
|
9885
10048
|
match?: (string | true)
|
|
@@ -9889,47 +10052,70 @@ type JsdocMatchDescription = []|[{
|
|
|
9889
10052
|
}]
|
|
9890
10053
|
// ----- jsdoc/match-name -----
|
|
9891
10054
|
type JsdocMatchName = []|[{
|
|
10055
|
+
|
|
9892
10056
|
match: {
|
|
10057
|
+
|
|
9893
10058
|
allowName?: string
|
|
10059
|
+
|
|
9894
10060
|
comment?: string
|
|
10061
|
+
|
|
9895
10062
|
context?: string
|
|
10063
|
+
|
|
9896
10064
|
disallowName?: string
|
|
10065
|
+
|
|
9897
10066
|
message?: string
|
|
10067
|
+
|
|
9898
10068
|
replacement?: string
|
|
10069
|
+
|
|
9899
10070
|
tags?: string[]
|
|
9900
10071
|
}[]
|
|
9901
10072
|
}]
|
|
9902
10073
|
// ----- jsdoc/multiline-blocks -----
|
|
9903
10074
|
type JsdocMultilineBlocks = []|[{
|
|
10075
|
+
|
|
9904
10076
|
allowMultipleTags?: boolean
|
|
10077
|
+
|
|
9905
10078
|
minimumLengthForMultiline?: number
|
|
10079
|
+
|
|
9906
10080
|
multilineTags?: ("*" | string[])
|
|
10081
|
+
|
|
9907
10082
|
noFinalLineText?: boolean
|
|
10083
|
+
|
|
9908
10084
|
noMultilineBlocks?: boolean
|
|
10085
|
+
|
|
9909
10086
|
noSingleLineBlocks?: boolean
|
|
10087
|
+
|
|
9910
10088
|
noZeroLineText?: boolean
|
|
10089
|
+
|
|
9911
10090
|
requireSingleLineUnderCount?: number
|
|
10091
|
+
|
|
9912
10092
|
singleLineTags?: string[]
|
|
9913
10093
|
}]
|
|
9914
10094
|
// ----- jsdoc/no-bad-blocks -----
|
|
9915
10095
|
type JsdocNoBadBlocks = []|[{
|
|
10096
|
+
|
|
9916
10097
|
ignore?: string[]
|
|
10098
|
+
|
|
9917
10099
|
preventAllMultiAsteriskBlocks?: boolean
|
|
9918
10100
|
}]
|
|
9919
10101
|
// ----- jsdoc/no-blank-blocks -----
|
|
9920
10102
|
type JsdocNoBlankBlocks = []|[{
|
|
10103
|
+
|
|
9921
10104
|
enableFixer?: boolean
|
|
9922
10105
|
}]
|
|
9923
10106
|
// ----- jsdoc/no-defaults -----
|
|
9924
10107
|
type JsdocNoDefaults = []|[{
|
|
10108
|
+
|
|
9925
10109
|
contexts?: (string | {
|
|
9926
10110
|
comment?: string
|
|
9927
10111
|
context?: string
|
|
9928
10112
|
})[]
|
|
10113
|
+
|
|
9929
10114
|
noOptionalParamNames?: boolean
|
|
9930
10115
|
}]
|
|
9931
10116
|
// ----- jsdoc/no-missing-syntax -----
|
|
9932
10117
|
type JsdocNoMissingSyntax = []|[{
|
|
10118
|
+
|
|
9933
10119
|
contexts?: (string | {
|
|
9934
10120
|
comment?: string
|
|
9935
10121
|
context?: string
|
|
@@ -9939,12 +10125,16 @@ type JsdocNoMissingSyntax = []|[{
|
|
|
9939
10125
|
}]
|
|
9940
10126
|
// ----- jsdoc/no-multi-asterisks -----
|
|
9941
10127
|
type JsdocNoMultiAsterisks = []|[{
|
|
10128
|
+
|
|
9942
10129
|
allowWhitespace?: boolean
|
|
10130
|
+
|
|
9943
10131
|
preventAtEnd?: boolean
|
|
10132
|
+
|
|
9944
10133
|
preventAtMiddleLines?: boolean
|
|
9945
10134
|
}]
|
|
9946
10135
|
// ----- jsdoc/no-restricted-syntax -----
|
|
9947
10136
|
type JsdocNoRestrictedSyntax = []|[{
|
|
10137
|
+
|
|
9948
10138
|
contexts: (string | {
|
|
9949
10139
|
comment?: string
|
|
9950
10140
|
context?: string
|
|
@@ -9953,6 +10143,7 @@ type JsdocNoRestrictedSyntax = []|[{
|
|
|
9953
10143
|
}]
|
|
9954
10144
|
// ----- jsdoc/no-types -----
|
|
9955
10145
|
type JsdocNoTypes = []|[{
|
|
10146
|
+
|
|
9956
10147
|
contexts?: (string | {
|
|
9957
10148
|
comment?: string
|
|
9958
10149
|
context?: string
|
|
@@ -9960,51 +10151,86 @@ type JsdocNoTypes = []|[{
|
|
|
9960
10151
|
}]
|
|
9961
10152
|
// ----- jsdoc/no-undefined-types -----
|
|
9962
10153
|
type JsdocNoUndefinedTypes = []|[{
|
|
10154
|
+
|
|
10155
|
+
checkUsedTypedefs?: boolean
|
|
10156
|
+
|
|
9963
10157
|
definedTypes?: string[]
|
|
10158
|
+
|
|
9964
10159
|
disableReporting?: boolean
|
|
10160
|
+
|
|
9965
10161
|
markVariablesAsUsed?: boolean
|
|
9966
10162
|
}]
|
|
10163
|
+
// ----- jsdoc/prefer-import-tag -----
|
|
10164
|
+
type JsdocPreferImportTag = []|[{
|
|
10165
|
+
|
|
10166
|
+
enableFixer?: boolean
|
|
10167
|
+
|
|
10168
|
+
exemptTypedefs?: boolean
|
|
10169
|
+
|
|
10170
|
+
outputType?: ("named-import" | "namespaced-import")
|
|
10171
|
+
}]
|
|
9967
10172
|
// ----- jsdoc/require-asterisk-prefix -----
|
|
9968
10173
|
type JsdocRequireAsteriskPrefix = []|[("always" | "never" | "any")]|[("always" | "never" | "any"), {
|
|
10174
|
+
|
|
9969
10175
|
tags?: {
|
|
10176
|
+
|
|
9970
10177
|
always?: string[]
|
|
10178
|
+
|
|
9971
10179
|
any?: string[]
|
|
10180
|
+
|
|
9972
10181
|
never?: string[]
|
|
9973
10182
|
}
|
|
9974
10183
|
}]
|
|
9975
10184
|
// ----- jsdoc/require-description -----
|
|
9976
10185
|
type JsdocRequireDescription = []|[{
|
|
10186
|
+
|
|
9977
10187
|
checkConstructors?: boolean
|
|
10188
|
+
|
|
9978
10189
|
checkGetters?: boolean
|
|
10190
|
+
|
|
9979
10191
|
checkSetters?: boolean
|
|
10192
|
+
|
|
9980
10193
|
contexts?: (string | {
|
|
9981
10194
|
comment?: string
|
|
9982
10195
|
context?: string
|
|
9983
10196
|
})[]
|
|
10197
|
+
|
|
9984
10198
|
descriptionStyle?: ("body" | "tag" | "any")
|
|
10199
|
+
|
|
9985
10200
|
exemptedBy?: string[]
|
|
9986
10201
|
}]
|
|
9987
10202
|
// ----- jsdoc/require-description-complete-sentence -----
|
|
9988
10203
|
type JsdocRequireDescriptionCompleteSentence = []|[{
|
|
10204
|
+
|
|
9989
10205
|
abbreviations?: string[]
|
|
10206
|
+
|
|
9990
10207
|
newlineBeforeCapsAssumesBadSentenceEnd?: boolean
|
|
10208
|
+
|
|
9991
10209
|
tags?: string[]
|
|
9992
10210
|
}]
|
|
9993
10211
|
// ----- jsdoc/require-example -----
|
|
9994
10212
|
type JsdocRequireExample = []|[{
|
|
10213
|
+
|
|
9995
10214
|
checkConstructors?: boolean
|
|
10215
|
+
|
|
9996
10216
|
checkGetters?: boolean
|
|
10217
|
+
|
|
9997
10218
|
checkSetters?: boolean
|
|
10219
|
+
|
|
9998
10220
|
contexts?: (string | {
|
|
9999
10221
|
comment?: string
|
|
10000
10222
|
context?: string
|
|
10001
10223
|
})[]
|
|
10224
|
+
|
|
10002
10225
|
enableFixer?: boolean
|
|
10226
|
+
|
|
10003
10227
|
exemptedBy?: string[]
|
|
10228
|
+
|
|
10004
10229
|
exemptNoArguments?: boolean
|
|
10005
10230
|
}]
|
|
10006
10231
|
// ----- jsdoc/require-file-overview -----
|
|
10007
10232
|
type JsdocRequireFileOverview = []|[{
|
|
10233
|
+
|
|
10008
10234
|
tags?: {
|
|
10009
10235
|
[k: string]: {
|
|
10010
10236
|
initialCommentsOnly?: boolean
|
|
@@ -10015,75 +10241,117 @@ type JsdocRequireFileOverview = []|[{
|
|
|
10015
10241
|
}]
|
|
10016
10242
|
// ----- jsdoc/require-hyphen-before-param-description -----
|
|
10017
10243
|
type JsdocRequireHyphenBeforeParamDescription = []|[("always" | "never")]|[("always" | "never"), {
|
|
10244
|
+
|
|
10018
10245
|
tags?: ({
|
|
10019
10246
|
[k: string]: ("always" | "never")
|
|
10020
10247
|
} | "any")
|
|
10021
10248
|
}]
|
|
10022
10249
|
// ----- jsdoc/require-jsdoc -----
|
|
10023
10250
|
type JsdocRequireJsdoc = []|[{
|
|
10251
|
+
|
|
10024
10252
|
checkConstructors?: boolean
|
|
10253
|
+
|
|
10025
10254
|
checkGetters?: (boolean | "no-setter")
|
|
10255
|
+
|
|
10026
10256
|
checkSetters?: (boolean | "no-getter")
|
|
10257
|
+
|
|
10027
10258
|
contexts?: (string | {
|
|
10028
10259
|
context?: string
|
|
10029
10260
|
inlineCommentBlock?: boolean
|
|
10030
10261
|
minLineCount?: number
|
|
10031
10262
|
})[]
|
|
10263
|
+
|
|
10032
10264
|
enableFixer?: boolean
|
|
10265
|
+
|
|
10033
10266
|
exemptEmptyConstructors?: boolean
|
|
10267
|
+
|
|
10034
10268
|
exemptEmptyFunctions?: boolean
|
|
10269
|
+
|
|
10035
10270
|
exemptOverloadedImplementations?: boolean
|
|
10271
|
+
|
|
10036
10272
|
fixerMessage?: string
|
|
10273
|
+
|
|
10037
10274
|
minLineCount?: number
|
|
10275
|
+
|
|
10038
10276
|
publicOnly?: (boolean | {
|
|
10039
10277
|
ancestorsOnly?: boolean
|
|
10040
10278
|
cjs?: boolean
|
|
10041
10279
|
esm?: boolean
|
|
10042
10280
|
window?: boolean
|
|
10043
10281
|
})
|
|
10282
|
+
|
|
10044
10283
|
require?: {
|
|
10284
|
+
|
|
10045
10285
|
ArrowFunctionExpression?: boolean
|
|
10286
|
+
|
|
10046
10287
|
ClassDeclaration?: boolean
|
|
10288
|
+
|
|
10047
10289
|
ClassExpression?: boolean
|
|
10290
|
+
|
|
10048
10291
|
FunctionDeclaration?: boolean
|
|
10292
|
+
|
|
10049
10293
|
FunctionExpression?: boolean
|
|
10294
|
+
|
|
10050
10295
|
MethodDefinition?: boolean
|
|
10051
10296
|
}
|
|
10297
|
+
|
|
10052
10298
|
skipInterveningOverloadedDeclarations?: boolean
|
|
10053
10299
|
}]
|
|
10054
10300
|
// ----- jsdoc/require-param -----
|
|
10055
10301
|
type JsdocRequireParam = []|[{
|
|
10302
|
+
|
|
10056
10303
|
autoIncrementBase?: number
|
|
10304
|
+
|
|
10057
10305
|
checkConstructors?: boolean
|
|
10306
|
+
|
|
10058
10307
|
checkDestructured?: boolean
|
|
10308
|
+
|
|
10059
10309
|
checkDestructuredRoots?: boolean
|
|
10310
|
+
|
|
10060
10311
|
checkGetters?: boolean
|
|
10312
|
+
|
|
10061
10313
|
checkRestProperty?: boolean
|
|
10314
|
+
|
|
10062
10315
|
checkSetters?: boolean
|
|
10316
|
+
|
|
10063
10317
|
checkTypesPattern?: string
|
|
10318
|
+
|
|
10064
10319
|
contexts?: (string | {
|
|
10065
10320
|
comment?: string
|
|
10066
10321
|
context?: string
|
|
10067
10322
|
})[]
|
|
10323
|
+
|
|
10068
10324
|
enableFixer?: boolean
|
|
10325
|
+
|
|
10069
10326
|
enableRestElementFixer?: boolean
|
|
10327
|
+
|
|
10070
10328
|
enableRootFixer?: boolean
|
|
10329
|
+
|
|
10071
10330
|
exemptedBy?: string[]
|
|
10331
|
+
|
|
10072
10332
|
ignoreWhenAllParamsMissing?: boolean
|
|
10333
|
+
|
|
10334
|
+
interfaceExemptsParamsCheck?: boolean
|
|
10335
|
+
|
|
10073
10336
|
unnamedRootBase?: string[]
|
|
10337
|
+
|
|
10074
10338
|
useDefaultObjectProperties?: boolean
|
|
10075
10339
|
}]
|
|
10076
10340
|
// ----- jsdoc/require-param-description -----
|
|
10077
10341
|
type JsdocRequireParamDescription = []|[{
|
|
10342
|
+
|
|
10078
10343
|
contexts?: (string | {
|
|
10079
10344
|
comment?: string
|
|
10080
10345
|
context?: string
|
|
10081
10346
|
})[]
|
|
10347
|
+
|
|
10082
10348
|
defaultDestructuredRootDescription?: string
|
|
10349
|
+
|
|
10083
10350
|
setDefaultDestructuredRootDescription?: boolean
|
|
10084
10351
|
}]
|
|
10085
10352
|
// ----- jsdoc/require-param-name -----
|
|
10086
10353
|
type JsdocRequireParamName = []|[{
|
|
10354
|
+
|
|
10087
10355
|
contexts?: (string | {
|
|
10088
10356
|
comment?: string
|
|
10089
10357
|
context?: string
|
|
@@ -10091,26 +10359,37 @@ type JsdocRequireParamName = []|[{
|
|
|
10091
10359
|
}]
|
|
10092
10360
|
// ----- jsdoc/require-param-type -----
|
|
10093
10361
|
type JsdocRequireParamType = []|[{
|
|
10362
|
+
|
|
10094
10363
|
contexts?: (string | {
|
|
10095
10364
|
comment?: string
|
|
10096
10365
|
context?: string
|
|
10097
10366
|
})[]
|
|
10367
|
+
|
|
10098
10368
|
defaultDestructuredRootType?: string
|
|
10369
|
+
|
|
10099
10370
|
setDefaultDestructuredRootType?: boolean
|
|
10100
10371
|
}]
|
|
10101
10372
|
// ----- jsdoc/require-returns -----
|
|
10102
10373
|
type JsdocRequireReturns = []|[{
|
|
10374
|
+
|
|
10103
10375
|
checkConstructors?: boolean
|
|
10376
|
+
|
|
10104
10377
|
checkGetters?: boolean
|
|
10378
|
+
|
|
10105
10379
|
contexts?: (string | {
|
|
10106
10380
|
comment?: string
|
|
10107
10381
|
context?: string
|
|
10108
10382
|
forceRequireReturn?: boolean
|
|
10109
10383
|
})[]
|
|
10384
|
+
|
|
10110
10385
|
enableFixer?: boolean
|
|
10386
|
+
|
|
10111
10387
|
exemptedBy?: string[]
|
|
10388
|
+
|
|
10112
10389
|
forceRequireReturn?: boolean
|
|
10390
|
+
|
|
10113
10391
|
forceReturnsWithAsync?: boolean
|
|
10392
|
+
|
|
10114
10393
|
publicOnly?: (boolean | {
|
|
10115
10394
|
ancestorsOnly?: boolean
|
|
10116
10395
|
cjs?: boolean
|
|
@@ -10120,12 +10399,18 @@ type JsdocRequireReturns = []|[{
|
|
|
10120
10399
|
}]
|
|
10121
10400
|
// ----- jsdoc/require-returns-check -----
|
|
10122
10401
|
type JsdocRequireReturnsCheck = []|[{
|
|
10402
|
+
|
|
10123
10403
|
exemptAsync?: boolean
|
|
10404
|
+
|
|
10124
10405
|
exemptGenerators?: boolean
|
|
10406
|
+
|
|
10407
|
+
noNativeTypes?: boolean
|
|
10408
|
+
|
|
10125
10409
|
reportMissingReturnForUndefinedTypes?: boolean
|
|
10126
10410
|
}]
|
|
10127
10411
|
// ----- jsdoc/require-returns-description -----
|
|
10128
10412
|
type JsdocRequireReturnsDescription = []|[{
|
|
10413
|
+
|
|
10129
10414
|
contexts?: (string | {
|
|
10130
10415
|
comment?: string
|
|
10131
10416
|
context?: string
|
|
@@ -10133,63 +10418,99 @@ type JsdocRequireReturnsDescription = []|[{
|
|
|
10133
10418
|
}]
|
|
10134
10419
|
// ----- jsdoc/require-returns-type -----
|
|
10135
10420
|
type JsdocRequireReturnsType = []|[{
|
|
10421
|
+
|
|
10136
10422
|
contexts?: (string | {
|
|
10137
10423
|
comment?: string
|
|
10138
10424
|
context?: string
|
|
10139
10425
|
})[]
|
|
10140
10426
|
}]
|
|
10427
|
+
// ----- jsdoc/require-tags -----
|
|
10428
|
+
type JsdocRequireTags = []|[{
|
|
10429
|
+
|
|
10430
|
+
tags?: (string | {
|
|
10431
|
+
context?: string
|
|
10432
|
+
tag?: string
|
|
10433
|
+
[k: string]: unknown | undefined
|
|
10434
|
+
})[]
|
|
10435
|
+
}]
|
|
10141
10436
|
// ----- jsdoc/require-template -----
|
|
10142
10437
|
type JsdocRequireTemplate = []|[{
|
|
10438
|
+
|
|
10143
10439
|
exemptedBy?: string[]
|
|
10440
|
+
|
|
10144
10441
|
requireSeparateTemplates?: boolean
|
|
10145
10442
|
}]
|
|
10146
10443
|
// ----- jsdoc/require-throws -----
|
|
10147
10444
|
type JsdocRequireThrows = []|[{
|
|
10445
|
+
|
|
10148
10446
|
contexts?: (string | {
|
|
10149
10447
|
comment?: string
|
|
10150
10448
|
context?: string
|
|
10151
10449
|
})[]
|
|
10450
|
+
|
|
10152
10451
|
exemptedBy?: string[]
|
|
10153
10452
|
}]
|
|
10154
10453
|
// ----- jsdoc/require-yields -----
|
|
10155
10454
|
type JsdocRequireYields = []|[{
|
|
10455
|
+
|
|
10156
10456
|
contexts?: (string | {
|
|
10157
10457
|
comment?: string
|
|
10158
10458
|
context?: string
|
|
10159
10459
|
})[]
|
|
10460
|
+
|
|
10160
10461
|
exemptedBy?: string[]
|
|
10462
|
+
|
|
10161
10463
|
forceRequireNext?: boolean
|
|
10464
|
+
|
|
10162
10465
|
forceRequireYields?: boolean
|
|
10466
|
+
|
|
10163
10467
|
next?: boolean
|
|
10468
|
+
|
|
10164
10469
|
nextWithGeneratorTag?: boolean
|
|
10470
|
+
|
|
10165
10471
|
withGeneratorTag?: boolean
|
|
10166
10472
|
}]
|
|
10167
10473
|
// ----- jsdoc/require-yields-check -----
|
|
10168
10474
|
type JsdocRequireYieldsCheck = []|[{
|
|
10475
|
+
|
|
10169
10476
|
checkGeneratorsOnly?: boolean
|
|
10477
|
+
|
|
10170
10478
|
contexts?: (string | {
|
|
10171
10479
|
comment?: string
|
|
10172
10480
|
context?: string
|
|
10173
10481
|
})[]
|
|
10174
|
-
|
|
10482
|
+
|
|
10175
10483
|
next?: boolean
|
|
10176
10484
|
}]
|
|
10177
10485
|
// ----- jsdoc/sort-tags -----
|
|
10178
10486
|
type JsdocSortTags = []|[{
|
|
10487
|
+
|
|
10179
10488
|
alphabetizeExtras?: boolean
|
|
10489
|
+
|
|
10180
10490
|
linesBetween?: number
|
|
10491
|
+
|
|
10181
10492
|
reportIntraTagGroupSpacing?: boolean
|
|
10493
|
+
|
|
10182
10494
|
reportTagGroupSpacing?: boolean
|
|
10495
|
+
|
|
10183
10496
|
tagSequence?: {
|
|
10497
|
+
|
|
10184
10498
|
tags?: string[]
|
|
10185
10499
|
}[]
|
|
10186
10500
|
}]
|
|
10187
10501
|
// ----- jsdoc/tag-lines -----
|
|
10188
10502
|
type JsdocTagLines = []|[("always" | "any" | "never")]|[("always" | "any" | "never"), {
|
|
10503
|
+
|
|
10189
10504
|
applyToEndTag?: boolean
|
|
10505
|
+
|
|
10190
10506
|
count?: number
|
|
10507
|
+
|
|
10191
10508
|
endLines?: (number | null)
|
|
10509
|
+
|
|
10510
|
+
maxBlockLines?: (number | null)
|
|
10511
|
+
|
|
10192
10512
|
startLines?: (number | null)
|
|
10513
|
+
|
|
10193
10514
|
tags?: {
|
|
10194
10515
|
[k: string]: {
|
|
10195
10516
|
count?: number
|
|
@@ -10199,26 +10520,88 @@ type JsdocTagLines = []|[("always" | "any" | "never")]|[("always" | "any" | "nev
|
|
|
10199
10520
|
}]
|
|
10200
10521
|
// ----- jsdoc/text-escaping -----
|
|
10201
10522
|
type JsdocTextEscaping = []|[{
|
|
10523
|
+
|
|
10202
10524
|
escapeHTML?: boolean
|
|
10525
|
+
|
|
10203
10526
|
escapeMarkdown?: boolean
|
|
10204
10527
|
}]
|
|
10528
|
+
// ----- jsdoc/ts-method-signature-style -----
|
|
10529
|
+
type JsdocTsMethodSignatureStyle = []|[("method" | "property")]|[("method" | "property"), {
|
|
10530
|
+
|
|
10531
|
+
enableFixer?: boolean
|
|
10532
|
+
}]
|
|
10533
|
+
// ----- jsdoc/ts-no-unnecessary-template-expression -----
|
|
10534
|
+
type JsdocTsNoUnnecessaryTemplateExpression = []|[{
|
|
10535
|
+
|
|
10536
|
+
enableFixer?: boolean
|
|
10537
|
+
}]
|
|
10538
|
+
// ----- jsdoc/ts-prefer-function-type -----
|
|
10539
|
+
type JsdocTsPreferFunctionType = []|[{
|
|
10540
|
+
|
|
10541
|
+
enableFixer?: boolean
|
|
10542
|
+
}]
|
|
10205
10543
|
// ----- jsdoc/type-formatting -----
|
|
10206
10544
|
type JsdocTypeFormatting = []|[{
|
|
10545
|
+
|
|
10207
10546
|
arrayBrackets?: ("angle" | "square")
|
|
10547
|
+
|
|
10548
|
+
arrowFunctionPostReturnMarkerSpacing?: string
|
|
10549
|
+
|
|
10550
|
+
arrowFunctionPreReturnMarkerSpacing?: string
|
|
10551
|
+
|
|
10208
10552
|
enableFixer?: boolean
|
|
10553
|
+
|
|
10554
|
+
functionOrClassParameterSpacing?: string
|
|
10555
|
+
|
|
10556
|
+
functionOrClassPostGenericSpacing?: string
|
|
10557
|
+
|
|
10558
|
+
functionOrClassPostReturnMarkerSpacing?: string
|
|
10559
|
+
|
|
10560
|
+
functionOrClassPreReturnMarkerSpacing?: string
|
|
10561
|
+
|
|
10562
|
+
functionOrClassTypeParameterSpacing?: string
|
|
10563
|
+
|
|
10564
|
+
genericAndTupleElementSpacing?: string
|
|
10565
|
+
|
|
10209
10566
|
genericDot?: boolean
|
|
10567
|
+
|
|
10568
|
+
keyValuePostColonSpacing?: string
|
|
10569
|
+
|
|
10570
|
+
keyValuePostKeySpacing?: string
|
|
10571
|
+
|
|
10572
|
+
keyValuePostOptionalSpacing?: string
|
|
10573
|
+
|
|
10574
|
+
keyValuePostVariadicSpacing?: string
|
|
10575
|
+
|
|
10576
|
+
methodQuotes?: ("double" | "single")
|
|
10577
|
+
|
|
10210
10578
|
objectFieldIndent?: string
|
|
10579
|
+
|
|
10211
10580
|
objectFieldQuote?: ("double" | "single" | null)
|
|
10581
|
+
|
|
10212
10582
|
objectFieldSeparator?: ("comma" | "comma-and-linebreak" | "linebreak" | "semicolon" | "semicolon-and-linebreak")
|
|
10583
|
+
|
|
10584
|
+
objectFieldSeparatorOptionalLinebreak?: boolean
|
|
10585
|
+
|
|
10213
10586
|
objectFieldSeparatorTrailingPunctuation?: boolean
|
|
10214
|
-
|
|
10587
|
+
|
|
10588
|
+
parameterDefaultValueSpacing?: string
|
|
10589
|
+
|
|
10590
|
+
postMethodNameSpacing?: string
|
|
10591
|
+
|
|
10592
|
+
postNewSpacing?: string
|
|
10593
|
+
|
|
10215
10594
|
separatorForSingleObjectField?: boolean
|
|
10595
|
+
|
|
10216
10596
|
stringQuotes?: ("double" | "single")
|
|
10597
|
+
|
|
10217
10598
|
typeBracketSpacing?: string
|
|
10599
|
+
|
|
10218
10600
|
unionSpacing?: string
|
|
10219
10601
|
}]
|
|
10220
10602
|
// ----- jsdoc/valid-types -----
|
|
10221
10603
|
type JsdocValidTypes = []|[{
|
|
10604
|
+
|
|
10222
10605
|
allowEmptyNamepaths?: boolean
|
|
10223
10606
|
}]
|
|
10224
10607
|
// ----- json-schema-validator/no-invalid -----
|
|
@@ -15628,6 +16011,10 @@ type UnicornTemplateIndent = []|[{
|
|
|
15628
16011
|
selectors?: string[]
|
|
15629
16012
|
comments?: string[]
|
|
15630
16013
|
}]
|
|
16014
|
+
// ----- unicorn/text-encoding-identifier-case -----
|
|
16015
|
+
type UnicornTextEncodingIdentifierCase = []|[{
|
|
16016
|
+
withDash?: boolean
|
|
16017
|
+
}]
|
|
15631
16018
|
// ----- unused-imports/no-unused-imports -----
|
|
15632
16019
|
type UnusedImportsNoUnusedImports = []|[(("all" | "local") | {
|
|
15633
16020
|
|