@luxass/eslint-config 5.3.0 → 5.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +286 -191
- package/dist/index.js +3 -7
- package/package.json +21 -21
package/dist/index.d.ts
CHANGED
|
@@ -1276,7 +1276,7 @@ interface RuleOptions {
|
|
|
1276
1276
|
* Reports invalid alignment of JSDoc block asterisks.
|
|
1277
1277
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-alignment.md#repos-sticky-header
|
|
1278
1278
|
*/
|
|
1279
|
-
'jsdoc/check-alignment'?: Linter.RuleEntry<
|
|
1279
|
+
'jsdoc/check-alignment'?: Linter.RuleEntry<JsdocCheckAlignment>;
|
|
1280
1280
|
/**
|
|
1281
1281
|
* Ensures that (JavaScript) examples within JSDoc adhere to ESLint rules.
|
|
1282
1282
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-examples.md#repos-sticky-header
|
|
@@ -1547,6 +1547,11 @@ interface RuleOptions {
|
|
|
1547
1547
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/text-escaping.md#repos-sticky-header
|
|
1548
1548
|
*/
|
|
1549
1549
|
'jsdoc/text-escaping'?: Linter.RuleEntry<JsdocTextEscaping>;
|
|
1550
|
+
/**
|
|
1551
|
+
* Formats JSDoc type values.
|
|
1552
|
+
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/type-formatting.md#repos-sticky-header
|
|
1553
|
+
*/
|
|
1554
|
+
'jsdoc/type-formatting'?: Linter.RuleEntry<JsdocTypeFormatting>;
|
|
1550
1555
|
/**
|
|
1551
1556
|
* Requires all types to be valid JSDoc or Closure compiler types without syntax errors.
|
|
1552
1557
|
* @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/valid-types.md#repos-sticky-header
|
|
@@ -1834,7 +1839,7 @@ interface RuleOptions {
|
|
|
1834
1839
|
* Enforce heading levels increment by one
|
|
1835
1840
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/heading-increment.md
|
|
1836
1841
|
*/
|
|
1837
|
-
'markdown/heading-increment'?: Linter.RuleEntry<
|
|
1842
|
+
'markdown/heading-increment'?: Linter.RuleEntry<MarkdownHeadingIncrement>;
|
|
1838
1843
|
/**
|
|
1839
1844
|
* Disallow bare URLs
|
|
1840
1845
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/no-bare-urls.md
|
|
@@ -1879,7 +1884,7 @@ interface RuleOptions {
|
|
|
1879
1884
|
* Disallow headings without a space after the hash characters
|
|
1880
1885
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/no-missing-atx-heading-space.md
|
|
1881
1886
|
*/
|
|
1882
|
-
'markdown/no-missing-atx-heading-space'?: Linter.RuleEntry<
|
|
1887
|
+
'markdown/no-missing-atx-heading-space'?: Linter.RuleEntry<MarkdownNoMissingAtxHeadingSpace>;
|
|
1883
1888
|
/**
|
|
1884
1889
|
* Disallow missing label references
|
|
1885
1890
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/no-missing-label-refs.md
|
|
@@ -1900,6 +1905,11 @@ interface RuleOptions {
|
|
|
1900
1905
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/no-reversed-media-syntax.md
|
|
1901
1906
|
*/
|
|
1902
1907
|
'markdown/no-reversed-media-syntax'?: Linter.RuleEntry<[]>;
|
|
1908
|
+
/**
|
|
1909
|
+
* Disallow spaces around emphasis markers
|
|
1910
|
+
* @see https://github.com/eslint/markdown/blob/main/docs/rules/no-space-in-emphasis.md
|
|
1911
|
+
*/
|
|
1912
|
+
'markdown/no-space-in-emphasis'?: Linter.RuleEntry<MarkdownNoSpaceInEmphasis>;
|
|
1903
1913
|
/**
|
|
1904
1914
|
* Disallow unused definitions
|
|
1905
1915
|
* @see https://github.com/eslint/markdown/blob/main/docs/rules/no-unused-definitions.md
|
|
@@ -3185,7 +3195,7 @@ interface RuleOptions {
|
|
|
3185
3195
|
*/
|
|
3186
3196
|
'pnpm/json-enforce-catalog'?: Linter.RuleEntry<PnpmJsonEnforceCatalog>;
|
|
3187
3197
|
/**
|
|
3188
|
-
* Prefer having pnpm settings in `pnpm-workspace.yaml` instead of `package.json`. This
|
|
3198
|
+
* Prefer having pnpm settings in `pnpm-workspace.yaml` instead of `package.json`. This requires pnpm v10.6+, see https://github.com/orgs/pnpm/discussions/9037.
|
|
3189
3199
|
* @see https://github.com/antfu/pnpm-workspace-utils/tree/main/packages/eslint-plugin-pnpm/src/rules/json/json-prefer-workspace-settings.test.ts
|
|
3190
3200
|
*/
|
|
3191
3201
|
'pnpm/json-prefer-workspace-settings'?: Linter.RuleEntry<PnpmJsonPreferWorkspaceSettings>;
|
|
@@ -3195,7 +3205,7 @@ interface RuleOptions {
|
|
|
3195
3205
|
*/
|
|
3196
3206
|
'pnpm/json-valid-catalog'?: Linter.RuleEntry<PnpmJsonValidCatalog>;
|
|
3197
3207
|
/**
|
|
3198
|
-
* Disallow
|
|
3208
|
+
* Disallow duplicate catalog items in `pnpm-workspace.yaml`
|
|
3199
3209
|
* @see https://github.com/antfu/pnpm-workspace-utils/tree/main/packages/eslint-plugin-pnpm/src/rules/yaml/yaml-no-duplicate-catalog-item.test.ts
|
|
3200
3210
|
*/
|
|
3201
3211
|
'pnpm/yaml-no-duplicate-catalog-item'?: Linter.RuleEntry<PnpmYamlNoDuplicateCatalogItem>;
|
|
@@ -3275,6 +3285,11 @@ interface RuleOptions {
|
|
|
3275
3285
|
* @see https://eslint.org/docs/latest/rules/prefer-template
|
|
3276
3286
|
*/
|
|
3277
3287
|
'prefer-template'?: Linter.RuleEntry<[]>;
|
|
3288
|
+
/**
|
|
3289
|
+
* Disallow losing originally caught error when re-throwing custom errors
|
|
3290
|
+
* @see https://eslint.org/docs/latest/rules/preserve-caught-error
|
|
3291
|
+
*/
|
|
3292
|
+
'preserve-caught-error'?: Linter.RuleEntry<PreserveCaughtError>;
|
|
3278
3293
|
/**
|
|
3279
3294
|
* Require quotes around object literal property names
|
|
3280
3295
|
* @see https://eslint.org/docs/latest/rules/quote-props
|
|
@@ -3690,7 +3705,7 @@ interface RuleOptions {
|
|
|
3690
3705
|
'react/no-nested-components'?: Linter.RuleEntry<[]>;
|
|
3691
3706
|
/**
|
|
3692
3707
|
* Disallow nesting lazy component declarations inside other components.
|
|
3693
|
-
* @see https://eslint-react.xyz/docs/rules/no-nested-component-
|
|
3708
|
+
* @see https://eslint-react.xyz/docs/rules/no-nested-lazy-component-declarations
|
|
3694
3709
|
*/
|
|
3695
3710
|
'react/no-nested-lazy-component-declarations'?: Linter.RuleEntry<[]>;
|
|
3696
3711
|
/**
|
|
@@ -4495,8 +4510,9 @@ interface RuleOptions {
|
|
|
4495
4510
|
*/
|
|
4496
4511
|
'style/jsx-pascal-case'?: Linter.RuleEntry<StyleJsxPascalCase>;
|
|
4497
4512
|
/**
|
|
4498
|
-
* Disallow multiple spaces between inline JSX props
|
|
4513
|
+
* Disallow multiple spaces between inline JSX props. Deprecated, use `no-multi-spaces` rule instead.
|
|
4499
4514
|
* @see https://eslint.style/rules/jsx-props-no-multi-spaces
|
|
4515
|
+
* @deprecated
|
|
4500
4516
|
*/
|
|
4501
4517
|
'style/jsx-props-no-multi-spaces'?: Linter.RuleEntry<[]>;
|
|
4502
4518
|
/**
|
|
@@ -4872,6 +4888,11 @@ interface RuleOptions {
|
|
|
4872
4888
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/expect-expect.md
|
|
4873
4889
|
*/
|
|
4874
4890
|
'test/expect-expect'?: Linter.RuleEntry<TestExpectExpect>;
|
|
4891
|
+
/**
|
|
4892
|
+
* enforce hoisted APIs to be on top of the file
|
|
4893
|
+
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/hoisted-apis-on-top.md
|
|
4894
|
+
*/
|
|
4895
|
+
'test/hoisted-apis-on-top'?: Linter.RuleEntry<[]>;
|
|
4875
4896
|
/**
|
|
4876
4897
|
* enforce a maximum number of expect per test
|
|
4877
4898
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/max-expects.md
|
|
@@ -5073,6 +5094,11 @@ interface RuleOptions {
|
|
|
5073
5094
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/prefer-expect-resolves.md
|
|
5074
5095
|
*/
|
|
5075
5096
|
'test/prefer-expect-resolves'?: Linter.RuleEntry<[]>;
|
|
5097
|
+
/**
|
|
5098
|
+
* enforce using `expectTypeOf` instead of `expect(typeof ...)`
|
|
5099
|
+
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/prefer-expect-type-of.md
|
|
5100
|
+
*/
|
|
5101
|
+
'test/prefer-expect-type-of'?: Linter.RuleEntry<[]>;
|
|
5076
5102
|
/**
|
|
5077
5103
|
* enforce having hooks in consistent order
|
|
5078
5104
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/prefer-hooks-in-order.md
|
|
@@ -5988,690 +6014,710 @@ interface RuleOptions {
|
|
|
5988
6014
|
'unicode-bom'?: Linter.RuleEntry<UnicodeBom>;
|
|
5989
6015
|
/**
|
|
5990
6016
|
* Improve regexes by making them shorter, consistent, and safer.
|
|
5991
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6017
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/better-regex.md
|
|
5992
6018
|
*/
|
|
5993
6019
|
'unicorn/better-regex'?: Linter.RuleEntry<UnicornBetterRegex>;
|
|
5994
6020
|
/**
|
|
5995
6021
|
* Enforce a specific parameter name in catch clauses.
|
|
5996
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6022
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/catch-error-name.md
|
|
5997
6023
|
*/
|
|
5998
6024
|
'unicorn/catch-error-name'?: Linter.RuleEntry<UnicornCatchErrorName>;
|
|
5999
6025
|
/**
|
|
6000
6026
|
* Enforce consistent assertion style with `node:assert`.
|
|
6001
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6027
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/consistent-assert.md
|
|
6002
6028
|
*/
|
|
6003
6029
|
'unicorn/consistent-assert'?: Linter.RuleEntry<[]>;
|
|
6004
6030
|
/**
|
|
6005
6031
|
* Prefer passing `Date` directly to the constructor when cloning.
|
|
6006
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6032
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/consistent-date-clone.md
|
|
6007
6033
|
*/
|
|
6008
6034
|
'unicorn/consistent-date-clone'?: Linter.RuleEntry<[]>;
|
|
6009
6035
|
/**
|
|
6010
6036
|
* Use destructured variables over properties.
|
|
6011
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6037
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/consistent-destructuring.md
|
|
6012
6038
|
*/
|
|
6013
6039
|
'unicorn/consistent-destructuring'?: Linter.RuleEntry<[]>;
|
|
6014
6040
|
/**
|
|
6015
6041
|
* Prefer consistent types when spreading a ternary in an array literal.
|
|
6016
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6042
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/consistent-empty-array-spread.md
|
|
6017
6043
|
*/
|
|
6018
6044
|
'unicorn/consistent-empty-array-spread'?: Linter.RuleEntry<[]>;
|
|
6019
6045
|
/**
|
|
6020
6046
|
* Enforce consistent style for element existence checks with `indexOf()`, `lastIndexOf()`, `findIndex()`, and `findLastIndex()`.
|
|
6021
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6047
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/consistent-existence-index-check.md
|
|
6022
6048
|
*/
|
|
6023
6049
|
'unicorn/consistent-existence-index-check'?: Linter.RuleEntry<[]>;
|
|
6024
6050
|
/**
|
|
6025
6051
|
* Move function definitions to the highest possible scope.
|
|
6026
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6052
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/consistent-function-scoping.md
|
|
6027
6053
|
*/
|
|
6028
6054
|
'unicorn/consistent-function-scoping'?: Linter.RuleEntry<UnicornConsistentFunctionScoping>;
|
|
6029
6055
|
/**
|
|
6030
6056
|
* Enforce correct `Error` subclassing.
|
|
6031
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6057
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/custom-error-definition.md
|
|
6032
6058
|
*/
|
|
6033
6059
|
'unicorn/custom-error-definition'?: Linter.RuleEntry<[]>;
|
|
6034
6060
|
/**
|
|
6035
6061
|
* Enforce no spaces between braces.
|
|
6036
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6062
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/empty-brace-spaces.md
|
|
6037
6063
|
*/
|
|
6038
6064
|
'unicorn/empty-brace-spaces'?: Linter.RuleEntry<[]>;
|
|
6039
6065
|
/**
|
|
6040
6066
|
* Enforce passing a `message` value when creating a built-in error.
|
|
6041
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6067
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/error-message.md
|
|
6042
6068
|
*/
|
|
6043
6069
|
'unicorn/error-message'?: Linter.RuleEntry<[]>;
|
|
6044
6070
|
/**
|
|
6045
6071
|
* Require escape sequences to use uppercase or lowercase values.
|
|
6046
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6072
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/escape-case.md
|
|
6047
6073
|
*/
|
|
6048
6074
|
'unicorn/escape-case'?: Linter.RuleEntry<UnicornEscapeCase>;
|
|
6049
6075
|
/**
|
|
6050
6076
|
* Add expiration conditions to TODO comments.
|
|
6051
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6077
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/expiring-todo-comments.md
|
|
6052
6078
|
*/
|
|
6053
6079
|
'unicorn/expiring-todo-comments'?: Linter.RuleEntry<UnicornExpiringTodoComments>;
|
|
6054
6080
|
/**
|
|
6055
6081
|
* Enforce explicitly comparing the `length` or `size` property of a value.
|
|
6056
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6082
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/explicit-length-check.md
|
|
6057
6083
|
*/
|
|
6058
6084
|
'unicorn/explicit-length-check'?: Linter.RuleEntry<UnicornExplicitLengthCheck>;
|
|
6059
6085
|
/**
|
|
6060
6086
|
* Enforce a case style for filenames.
|
|
6061
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6087
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/filename-case.md
|
|
6062
6088
|
*/
|
|
6063
6089
|
'unicorn/filename-case'?: Linter.RuleEntry<UnicornFilenameCase>;
|
|
6064
6090
|
/**
|
|
6065
6091
|
* Enforce specific import styles per module.
|
|
6066
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6092
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/import-style.md
|
|
6067
6093
|
*/
|
|
6068
6094
|
'unicorn/import-style'?: Linter.RuleEntry<UnicornImportStyle>;
|
|
6069
6095
|
/**
|
|
6070
6096
|
* Enforce the use of `new` for all builtins, except `String`, `Number`, `Boolean`, `Symbol` and `BigInt`.
|
|
6071
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6097
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/new-for-builtins.md
|
|
6072
6098
|
*/
|
|
6073
6099
|
'unicorn/new-for-builtins'?: Linter.RuleEntry<[]>;
|
|
6074
6100
|
/**
|
|
6075
6101
|
* Enforce specifying rules to disable in `eslint-disable` comments.
|
|
6076
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6102
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-abusive-eslint-disable.md
|
|
6077
6103
|
*/
|
|
6078
6104
|
'unicorn/no-abusive-eslint-disable'?: Linter.RuleEntry<[]>;
|
|
6079
6105
|
/**
|
|
6080
6106
|
* Disallow recursive access to `this` within getters and setters.
|
|
6081
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6107
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-accessor-recursion.md
|
|
6082
6108
|
*/
|
|
6083
6109
|
'unicorn/no-accessor-recursion'?: Linter.RuleEntry<[]>;
|
|
6084
6110
|
/**
|
|
6085
6111
|
* Disallow anonymous functions and classes as the default export.
|
|
6086
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6112
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-anonymous-default-export.md
|
|
6087
6113
|
*/
|
|
6088
6114
|
'unicorn/no-anonymous-default-export'?: Linter.RuleEntry<[]>;
|
|
6089
6115
|
/**
|
|
6090
6116
|
* Prevent passing a function reference directly to iterator methods.
|
|
6091
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6117
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-array-callback-reference.md
|
|
6092
6118
|
*/
|
|
6093
6119
|
'unicorn/no-array-callback-reference'?: Linter.RuleEntry<[]>;
|
|
6094
6120
|
/**
|
|
6095
6121
|
* Prefer `for…of` over the `forEach` method.
|
|
6096
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6122
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-array-for-each.md
|
|
6097
6123
|
*/
|
|
6098
6124
|
'unicorn/no-array-for-each'?: Linter.RuleEntry<[]>;
|
|
6099
6125
|
/**
|
|
6100
6126
|
* Disallow using the `this` argument in array methods.
|
|
6101
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6127
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-array-method-this-argument.md
|
|
6102
6128
|
*/
|
|
6103
6129
|
'unicorn/no-array-method-this-argument'?: Linter.RuleEntry<[]>;
|
|
6104
6130
|
/**
|
|
6105
6131
|
* Replaced by `unicorn/prefer-single-call` which covers more cases.
|
|
6106
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6132
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/deprecated-rules.md#no-array-push-push
|
|
6107
6133
|
* @deprecated
|
|
6108
6134
|
*/
|
|
6109
6135
|
'unicorn/no-array-push-push'?: Linter.RuleEntry<[]>;
|
|
6110
6136
|
/**
|
|
6111
6137
|
* Disallow `Array#reduce()` and `Array#reduceRight()`.
|
|
6112
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6138
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-array-reduce.md
|
|
6113
6139
|
*/
|
|
6114
6140
|
'unicorn/no-array-reduce'?: Linter.RuleEntry<UnicornNoArrayReduce>;
|
|
6115
6141
|
/**
|
|
6116
6142
|
* Prefer `Array#toReversed()` over `Array#reverse()`.
|
|
6117
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6143
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-array-reverse.md
|
|
6118
6144
|
*/
|
|
6119
6145
|
'unicorn/no-array-reverse'?: Linter.RuleEntry<UnicornNoArrayReverse>;
|
|
6146
|
+
/**
|
|
6147
|
+
* Prefer `Array#toSorted()` over `Array#sort()`.
|
|
6148
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-array-sort.md
|
|
6149
|
+
*/
|
|
6150
|
+
'unicorn/no-array-sort'?: Linter.RuleEntry<UnicornNoArraySort>;
|
|
6120
6151
|
/**
|
|
6121
6152
|
* Disallow member access from await expression.
|
|
6122
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6153
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-await-expression-member.md
|
|
6123
6154
|
*/
|
|
6124
6155
|
'unicorn/no-await-expression-member'?: Linter.RuleEntry<[]>;
|
|
6125
6156
|
/**
|
|
6126
6157
|
* Disallow using `await` in `Promise` method parameters.
|
|
6127
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6158
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-await-in-promise-methods.md
|
|
6128
6159
|
*/
|
|
6129
6160
|
'unicorn/no-await-in-promise-methods'?: Linter.RuleEntry<[]>;
|
|
6130
6161
|
/**
|
|
6131
6162
|
* Do not use leading/trailing space between `console.log` parameters.
|
|
6132
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6163
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-console-spaces.md
|
|
6133
6164
|
*/
|
|
6134
6165
|
'unicorn/no-console-spaces'?: Linter.RuleEntry<[]>;
|
|
6135
6166
|
/**
|
|
6136
6167
|
* Do not use `document.cookie` directly.
|
|
6137
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6168
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-document-cookie.md
|
|
6138
6169
|
*/
|
|
6139
6170
|
'unicorn/no-document-cookie'?: Linter.RuleEntry<[]>;
|
|
6140
6171
|
/**
|
|
6141
6172
|
* Disallow empty files.
|
|
6142
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6173
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-empty-file.md
|
|
6143
6174
|
*/
|
|
6144
6175
|
'unicorn/no-empty-file'?: Linter.RuleEntry<[]>;
|
|
6145
6176
|
/**
|
|
6146
6177
|
* Do not use a `for` loop that can be replaced with a `for-of` loop.
|
|
6147
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6178
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-for-loop.md
|
|
6148
6179
|
*/
|
|
6149
6180
|
'unicorn/no-for-loop'?: Linter.RuleEntry<[]>;
|
|
6150
6181
|
/**
|
|
6151
6182
|
* Enforce the use of Unicode escapes instead of hexadecimal escapes.
|
|
6152
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6183
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-hex-escape.md
|
|
6153
6184
|
*/
|
|
6154
6185
|
'unicorn/no-hex-escape'?: Linter.RuleEntry<[]>;
|
|
6155
6186
|
/**
|
|
6156
6187
|
* Replaced by `unicorn/no-instanceof-builtins` which covers more cases.
|
|
6157
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6188
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/deprecated-rules.md#no-instanceof-array
|
|
6158
6189
|
* @deprecated
|
|
6159
6190
|
*/
|
|
6160
6191
|
'unicorn/no-instanceof-array'?: Linter.RuleEntry<[]>;
|
|
6161
6192
|
/**
|
|
6162
6193
|
* Disallow `instanceof` with built-in objects
|
|
6163
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6194
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-instanceof-builtins.md
|
|
6164
6195
|
*/
|
|
6165
6196
|
'unicorn/no-instanceof-builtins'?: Linter.RuleEntry<UnicornNoInstanceofBuiltins>;
|
|
6166
6197
|
/**
|
|
6167
6198
|
* Disallow invalid options in `fetch()` and `new Request()`.
|
|
6168
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6199
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-invalid-fetch-options.md
|
|
6169
6200
|
*/
|
|
6170
6201
|
'unicorn/no-invalid-fetch-options'?: Linter.RuleEntry<[]>;
|
|
6171
6202
|
/**
|
|
6172
6203
|
* Prevent calling `EventTarget#removeEventListener()` with the result of an expression.
|
|
6173
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6204
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-invalid-remove-event-listener.md
|
|
6174
6205
|
*/
|
|
6175
6206
|
'unicorn/no-invalid-remove-event-listener'?: Linter.RuleEntry<[]>;
|
|
6176
6207
|
/**
|
|
6177
6208
|
* Disallow identifiers starting with `new` or `class`.
|
|
6178
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6209
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-keyword-prefix.md
|
|
6179
6210
|
*/
|
|
6180
6211
|
'unicorn/no-keyword-prefix'?: Linter.RuleEntry<UnicornNoKeywordPrefix>;
|
|
6181
6212
|
/**
|
|
6182
6213
|
* Replaced by `unicorn/no-unnecessary-slice-end` which covers more cases.
|
|
6183
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6214
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/deprecated-rules.md#no-length-as-slice-end
|
|
6184
6215
|
* @deprecated
|
|
6185
6216
|
*/
|
|
6186
6217
|
'unicorn/no-length-as-slice-end'?: Linter.RuleEntry<[]>;
|
|
6187
6218
|
/**
|
|
6188
6219
|
* Disallow `if` statements as the only statement in `if` blocks without `else`.
|
|
6189
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6220
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-lonely-if.md
|
|
6190
6221
|
*/
|
|
6191
6222
|
'unicorn/no-lonely-if'?: Linter.RuleEntry<[]>;
|
|
6192
6223
|
/**
|
|
6193
6224
|
* Disallow a magic number as the `depth` argument in `Array#flat(…).`
|
|
6194
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6225
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-magic-array-flat-depth.md
|
|
6195
6226
|
*/
|
|
6196
6227
|
'unicorn/no-magic-array-flat-depth'?: Linter.RuleEntry<[]>;
|
|
6197
6228
|
/**
|
|
6198
6229
|
* Disallow named usage of default import and export.
|
|
6199
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6230
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-named-default.md
|
|
6200
6231
|
*/
|
|
6201
6232
|
'unicorn/no-named-default'?: Linter.RuleEntry<[]>;
|
|
6202
6233
|
/**
|
|
6203
6234
|
* Disallow negated conditions.
|
|
6204
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6235
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-negated-condition.md
|
|
6205
6236
|
*/
|
|
6206
6237
|
'unicorn/no-negated-condition'?: Linter.RuleEntry<[]>;
|
|
6207
6238
|
/**
|
|
6208
6239
|
* Disallow negated expression in equality check.
|
|
6209
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6240
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-negation-in-equality-check.md
|
|
6210
6241
|
*/
|
|
6211
6242
|
'unicorn/no-negation-in-equality-check'?: Linter.RuleEntry<[]>;
|
|
6212
6243
|
/**
|
|
6213
6244
|
* Disallow nested ternary expressions.
|
|
6214
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6245
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-nested-ternary.md
|
|
6215
6246
|
*/
|
|
6216
6247
|
'unicorn/no-nested-ternary'?: Linter.RuleEntry<[]>;
|
|
6217
6248
|
/**
|
|
6218
6249
|
* Disallow `new Array()`.
|
|
6219
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6250
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-new-array.md
|
|
6220
6251
|
*/
|
|
6221
6252
|
'unicorn/no-new-array'?: Linter.RuleEntry<[]>;
|
|
6222
6253
|
/**
|
|
6223
6254
|
* Enforce the use of `Buffer.from()` and `Buffer.alloc()` instead of the deprecated `new Buffer()`.
|
|
6224
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6255
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-new-buffer.md
|
|
6225
6256
|
*/
|
|
6226
6257
|
'unicorn/no-new-buffer'?: Linter.RuleEntry<[]>;
|
|
6227
6258
|
/**
|
|
6228
6259
|
* Disallow the use of the `null` literal.
|
|
6229
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6260
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-null.md
|
|
6230
6261
|
*/
|
|
6231
6262
|
'unicorn/no-null'?: Linter.RuleEntry<UnicornNoNull>;
|
|
6232
6263
|
/**
|
|
6233
6264
|
* Disallow the use of objects as default parameters.
|
|
6234
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6265
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-object-as-default-parameter.md
|
|
6235
6266
|
*/
|
|
6236
6267
|
'unicorn/no-object-as-default-parameter'?: Linter.RuleEntry<[]>;
|
|
6237
6268
|
/**
|
|
6238
6269
|
* Disallow `process.exit()`.
|
|
6239
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6270
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-process-exit.md
|
|
6240
6271
|
*/
|
|
6241
6272
|
'unicorn/no-process-exit'?: Linter.RuleEntry<[]>;
|
|
6242
6273
|
/**
|
|
6243
6274
|
* Disallow passing single-element arrays to `Promise` methods.
|
|
6244
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6275
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-single-promise-in-promise-methods.md
|
|
6245
6276
|
*/
|
|
6246
6277
|
'unicorn/no-single-promise-in-promise-methods'?: Linter.RuleEntry<[]>;
|
|
6247
6278
|
/**
|
|
6248
6279
|
* Disallow classes that only have static members.
|
|
6249
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6280
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-static-only-class.md
|
|
6250
6281
|
*/
|
|
6251
6282
|
'unicorn/no-static-only-class'?: Linter.RuleEntry<[]>;
|
|
6252
6283
|
/**
|
|
6253
6284
|
* Disallow `then` property.
|
|
6254
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6285
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-thenable.md
|
|
6255
6286
|
*/
|
|
6256
6287
|
'unicorn/no-thenable'?: Linter.RuleEntry<[]>;
|
|
6257
6288
|
/**
|
|
6258
6289
|
* Disallow assigning `this` to a variable.
|
|
6259
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6290
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-this-assignment.md
|
|
6260
6291
|
*/
|
|
6261
6292
|
'unicorn/no-this-assignment'?: Linter.RuleEntry<[]>;
|
|
6262
6293
|
/**
|
|
6263
6294
|
* Disallow comparing `undefined` using `typeof`.
|
|
6264
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6295
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-typeof-undefined.md
|
|
6265
6296
|
*/
|
|
6266
6297
|
'unicorn/no-typeof-undefined'?: Linter.RuleEntry<UnicornNoTypeofUndefined>;
|
|
6267
6298
|
/**
|
|
6268
6299
|
* Disallow using `1` as the `depth` argument of `Array#flat()`.
|
|
6269
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6300
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unnecessary-array-flat-depth.md
|
|
6270
6301
|
*/
|
|
6271
6302
|
'unicorn/no-unnecessary-array-flat-depth'?: Linter.RuleEntry<[]>;
|
|
6272
6303
|
/**
|
|
6273
6304
|
* Disallow using `.length` or `Infinity` as the `deleteCount` or `skipCount` argument of `Array#{splice,toSpliced}()`.
|
|
6274
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6305
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unnecessary-array-splice-count.md
|
|
6275
6306
|
*/
|
|
6276
6307
|
'unicorn/no-unnecessary-array-splice-count'?: Linter.RuleEntry<[]>;
|
|
6277
6308
|
/**
|
|
6278
6309
|
* Disallow awaiting non-promise values.
|
|
6279
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6310
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unnecessary-await.md
|
|
6280
6311
|
*/
|
|
6281
6312
|
'unicorn/no-unnecessary-await'?: Linter.RuleEntry<[]>;
|
|
6282
6313
|
/**
|
|
6283
6314
|
* Enforce the use of built-in methods instead of unnecessary polyfills.
|
|
6284
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6315
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unnecessary-polyfills.md
|
|
6285
6316
|
*/
|
|
6286
6317
|
'unicorn/no-unnecessary-polyfills'?: Linter.RuleEntry<UnicornNoUnnecessaryPolyfills>;
|
|
6287
6318
|
/**
|
|
6288
6319
|
* Disallow using `.length` or `Infinity` as the `end` argument of `{Array,String,TypedArray}#slice()`.
|
|
6289
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6320
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unnecessary-slice-end.md
|
|
6290
6321
|
*/
|
|
6291
6322
|
'unicorn/no-unnecessary-slice-end'?: Linter.RuleEntry<[]>;
|
|
6292
6323
|
/**
|
|
6293
6324
|
* Disallow unreadable array destructuring.
|
|
6294
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6325
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unreadable-array-destructuring.md
|
|
6295
6326
|
*/
|
|
6296
6327
|
'unicorn/no-unreadable-array-destructuring'?: Linter.RuleEntry<[]>;
|
|
6297
6328
|
/**
|
|
6298
6329
|
* Disallow unreadable IIFEs.
|
|
6299
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6330
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unreadable-iife.md
|
|
6300
6331
|
*/
|
|
6301
6332
|
'unicorn/no-unreadable-iife'?: Linter.RuleEntry<[]>;
|
|
6302
6333
|
/**
|
|
6303
6334
|
* Disallow unused object properties.
|
|
6304
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6335
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-unused-properties.md
|
|
6305
6336
|
*/
|
|
6306
6337
|
'unicorn/no-unused-properties'?: Linter.RuleEntry<[]>;
|
|
6307
6338
|
/**
|
|
6308
6339
|
* Disallow unnecessary `Error.captureStackTrace(…)`.
|
|
6309
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6340
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-error-capture-stack-trace.md
|
|
6310
6341
|
*/
|
|
6311
6342
|
'unicorn/no-useless-error-capture-stack-trace'?: Linter.RuleEntry<[]>;
|
|
6312
6343
|
/**
|
|
6313
6344
|
* Disallow useless fallback when spreading in object literals.
|
|
6314
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6345
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-fallback-in-spread.md
|
|
6315
6346
|
*/
|
|
6316
6347
|
'unicorn/no-useless-fallback-in-spread'?: Linter.RuleEntry<[]>;
|
|
6317
6348
|
/**
|
|
6318
6349
|
* Disallow useless array length check.
|
|
6319
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6350
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-length-check.md
|
|
6320
6351
|
*/
|
|
6321
6352
|
'unicorn/no-useless-length-check'?: Linter.RuleEntry<[]>;
|
|
6322
6353
|
/**
|
|
6323
6354
|
* Disallow returning/yielding `Promise.resolve/reject()` in async functions or promise callbacks
|
|
6324
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6355
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-promise-resolve-reject.md
|
|
6325
6356
|
*/
|
|
6326
6357
|
'unicorn/no-useless-promise-resolve-reject'?: Linter.RuleEntry<[]>;
|
|
6327
6358
|
/**
|
|
6328
6359
|
* Disallow unnecessary spread.
|
|
6329
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6360
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-spread.md
|
|
6330
6361
|
*/
|
|
6331
6362
|
'unicorn/no-useless-spread'?: Linter.RuleEntry<[]>;
|
|
6332
6363
|
/**
|
|
6333
6364
|
* Disallow useless case in switch statements.
|
|
6334
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6365
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-switch-case.md
|
|
6335
6366
|
*/
|
|
6336
6367
|
'unicorn/no-useless-switch-case'?: Linter.RuleEntry<[]>;
|
|
6337
6368
|
/**
|
|
6338
6369
|
* Disallow useless `undefined`.
|
|
6339
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6370
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-useless-undefined.md
|
|
6340
6371
|
*/
|
|
6341
6372
|
'unicorn/no-useless-undefined'?: Linter.RuleEntry<UnicornNoUselessUndefined>;
|
|
6342
6373
|
/**
|
|
6343
6374
|
* Disallow number literals with zero fractions or dangling dots.
|
|
6344
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6375
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/no-zero-fractions.md
|
|
6345
6376
|
*/
|
|
6346
6377
|
'unicorn/no-zero-fractions'?: Linter.RuleEntry<[]>;
|
|
6347
6378
|
/**
|
|
6348
6379
|
* Enforce proper case for numeric literals.
|
|
6349
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6380
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/number-literal-case.md
|
|
6350
6381
|
*/
|
|
6351
6382
|
'unicorn/number-literal-case'?: Linter.RuleEntry<UnicornNumberLiteralCase>;
|
|
6352
6383
|
/**
|
|
6353
6384
|
* Enforce the style of numeric separators by correctly grouping digits.
|
|
6354
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6385
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/numeric-separators-style.md
|
|
6355
6386
|
*/
|
|
6356
6387
|
'unicorn/numeric-separators-style'?: Linter.RuleEntry<UnicornNumericSeparatorsStyle>;
|
|
6357
6388
|
/**
|
|
6358
6389
|
* Prefer `.addEventListener()` and `.removeEventListener()` over `on`-functions.
|
|
6359
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6390
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-add-event-listener.md
|
|
6360
6391
|
*/
|
|
6361
6392
|
'unicorn/prefer-add-event-listener'?: Linter.RuleEntry<UnicornPreferAddEventListener>;
|
|
6362
6393
|
/**
|
|
6363
6394
|
* Prefer `.find(…)` and `.findLast(…)` over the first or last element from `.filter(…)`.
|
|
6364
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6395
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-array-find.md
|
|
6365
6396
|
*/
|
|
6366
6397
|
'unicorn/prefer-array-find'?: Linter.RuleEntry<UnicornPreferArrayFind>;
|
|
6367
6398
|
/**
|
|
6368
6399
|
* Prefer `Array#flat()` over legacy techniques to flatten arrays.
|
|
6369
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6400
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-array-flat.md
|
|
6370
6401
|
*/
|
|
6371
6402
|
'unicorn/prefer-array-flat'?: Linter.RuleEntry<UnicornPreferArrayFlat>;
|
|
6372
6403
|
/**
|
|
6373
6404
|
* Prefer `.flatMap(…)` over `.map(…).flat()`.
|
|
6374
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6405
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-array-flat-map.md
|
|
6375
6406
|
*/
|
|
6376
6407
|
'unicorn/prefer-array-flat-map'?: Linter.RuleEntry<[]>;
|
|
6377
6408
|
/**
|
|
6378
6409
|
* Prefer `Array#{indexOf,lastIndexOf}()` over `Array#{findIndex,findLastIndex}()` when looking for the index of an item.
|
|
6379
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6410
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-array-index-of.md
|
|
6380
6411
|
*/
|
|
6381
6412
|
'unicorn/prefer-array-index-of'?: Linter.RuleEntry<[]>;
|
|
6382
6413
|
/**
|
|
6383
6414
|
* Prefer `.some(…)` over `.filter(…).length` check and `.{find,findLast,findIndex,findLastIndex}(…)`.
|
|
6384
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6415
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-array-some.md
|
|
6385
6416
|
*/
|
|
6386
6417
|
'unicorn/prefer-array-some'?: Linter.RuleEntry<[]>;
|
|
6387
6418
|
/**
|
|
6388
6419
|
* Prefer `.at()` method for index access and `String#charAt()`.
|
|
6389
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6420
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-at.md
|
|
6390
6421
|
*/
|
|
6391
6422
|
'unicorn/prefer-at'?: Linter.RuleEntry<UnicornPreferAt>;
|
|
6423
|
+
/**
|
|
6424
|
+
* Prefer `BigInt` literals over the constructor.
|
|
6425
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-bigint-literals.md
|
|
6426
|
+
*/
|
|
6427
|
+
'unicorn/prefer-bigint-literals'?: Linter.RuleEntry<[]>;
|
|
6392
6428
|
/**
|
|
6393
6429
|
* Prefer `Blob#arrayBuffer()` over `FileReader#readAsArrayBuffer(…)` and `Blob#text()` over `FileReader#readAsText(…)`.
|
|
6394
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6430
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-blob-reading-methods.md
|
|
6395
6431
|
*/
|
|
6396
6432
|
'unicorn/prefer-blob-reading-methods'?: Linter.RuleEntry<[]>;
|
|
6397
6433
|
/**
|
|
6398
6434
|
* Prefer class field declarations over `this` assignments in constructors.
|
|
6399
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6435
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-class-fields.md
|
|
6400
6436
|
*/
|
|
6401
6437
|
'unicorn/prefer-class-fields'?: Linter.RuleEntry<[]>;
|
|
6438
|
+
/**
|
|
6439
|
+
* Prefer using `Element#classList.toggle()` to toggle class names.
|
|
6440
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-classlist-toggle.md
|
|
6441
|
+
*/
|
|
6442
|
+
'unicorn/prefer-classlist-toggle'?: Linter.RuleEntry<[]>;
|
|
6402
6443
|
/**
|
|
6403
6444
|
* Prefer `String#codePointAt(…)` over `String#charCodeAt(…)` and `String.fromCodePoint(…)` over `String.fromCharCode(…)`.
|
|
6404
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6445
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-code-point.md
|
|
6405
6446
|
*/
|
|
6406
6447
|
'unicorn/prefer-code-point'?: Linter.RuleEntry<[]>;
|
|
6407
6448
|
/**
|
|
6408
6449
|
* Prefer `Date.now()` to get the number of milliseconds since the Unix Epoch.
|
|
6409
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6450
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-date-now.md
|
|
6410
6451
|
*/
|
|
6411
6452
|
'unicorn/prefer-date-now'?: Linter.RuleEntry<[]>;
|
|
6412
6453
|
/**
|
|
6413
6454
|
* Prefer default parameters over reassignment.
|
|
6414
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6455
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-default-parameters.md
|
|
6415
6456
|
*/
|
|
6416
6457
|
'unicorn/prefer-default-parameters'?: Linter.RuleEntry<[]>;
|
|
6417
6458
|
/**
|
|
6418
6459
|
* Prefer `Node#append()` over `Node#appendChild()`.
|
|
6419
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6460
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-dom-node-append.md
|
|
6420
6461
|
*/
|
|
6421
6462
|
'unicorn/prefer-dom-node-append'?: Linter.RuleEntry<[]>;
|
|
6422
6463
|
/**
|
|
6423
6464
|
* Prefer using `.dataset` on DOM elements over calling attribute methods.
|
|
6424
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6465
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-dom-node-dataset.md
|
|
6425
6466
|
*/
|
|
6426
6467
|
'unicorn/prefer-dom-node-dataset'?: Linter.RuleEntry<[]>;
|
|
6427
6468
|
/**
|
|
6428
6469
|
* Prefer `childNode.remove()` over `parentNode.removeChild(childNode)`.
|
|
6429
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6470
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-dom-node-remove.md
|
|
6430
6471
|
*/
|
|
6431
6472
|
'unicorn/prefer-dom-node-remove'?: Linter.RuleEntry<[]>;
|
|
6432
6473
|
/**
|
|
6433
6474
|
* Prefer `.textContent` over `.innerText`.
|
|
6434
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6475
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-dom-node-text-content.md
|
|
6435
6476
|
*/
|
|
6436
6477
|
'unicorn/prefer-dom-node-text-content'?: Linter.RuleEntry<[]>;
|
|
6437
6478
|
/**
|
|
6438
6479
|
* Prefer `EventTarget` over `EventEmitter`.
|
|
6439
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6480
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-event-target.md
|
|
6440
6481
|
*/
|
|
6441
6482
|
'unicorn/prefer-event-target'?: Linter.RuleEntry<[]>;
|
|
6442
6483
|
/**
|
|
6443
6484
|
* Prefer `export…from` when re-exporting.
|
|
6444
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6485
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-export-from.md
|
|
6445
6486
|
*/
|
|
6446
6487
|
'unicorn/prefer-export-from'?: Linter.RuleEntry<UnicornPreferExportFrom>;
|
|
6447
6488
|
/**
|
|
6448
6489
|
* Prefer `globalThis` over `window`, `self`, and `global`.
|
|
6449
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6490
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-global-this.md
|
|
6450
6491
|
*/
|
|
6451
6492
|
'unicorn/prefer-global-this'?: Linter.RuleEntry<[]>;
|
|
6452
6493
|
/**
|
|
6453
6494
|
* Prefer `import.meta.{dirname,filename}` over legacy techniques for getting file paths.
|
|
6454
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6495
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-import-meta-properties.md
|
|
6455
6496
|
*/
|
|
6456
6497
|
'unicorn/prefer-import-meta-properties'?: Linter.RuleEntry<[]>;
|
|
6457
6498
|
/**
|
|
6458
6499
|
* Prefer `.includes()` over `.indexOf()`, `.lastIndexOf()`, and `Array#some()` when checking for existence or non-existence.
|
|
6459
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6500
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-includes.md
|
|
6460
6501
|
*/
|
|
6461
6502
|
'unicorn/prefer-includes'?: Linter.RuleEntry<[]>;
|
|
6462
6503
|
/**
|
|
6463
6504
|
* Prefer reading a JSON file as a buffer.
|
|
6464
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6505
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-json-parse-buffer.md
|
|
6465
6506
|
*/
|
|
6466
6507
|
'unicorn/prefer-json-parse-buffer'?: Linter.RuleEntry<[]>;
|
|
6467
6508
|
/**
|
|
6468
6509
|
* Prefer `KeyboardEvent#key` over `KeyboardEvent#keyCode`.
|
|
6469
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6510
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-keyboard-event-key.md
|
|
6470
6511
|
*/
|
|
6471
6512
|
'unicorn/prefer-keyboard-event-key'?: Linter.RuleEntry<[]>;
|
|
6472
6513
|
/**
|
|
6473
6514
|
* Prefer using a logical operator over a ternary.
|
|
6474
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6515
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-logical-operator-over-ternary.md
|
|
6475
6516
|
*/
|
|
6476
6517
|
'unicorn/prefer-logical-operator-over-ternary'?: Linter.RuleEntry<[]>;
|
|
6477
6518
|
/**
|
|
6478
6519
|
* Prefer `Math.min()` and `Math.max()` over ternaries for simple comparisons.
|
|
6479
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6520
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-math-min-max.md
|
|
6480
6521
|
*/
|
|
6481
6522
|
'unicorn/prefer-math-min-max'?: Linter.RuleEntry<[]>;
|
|
6482
6523
|
/**
|
|
6483
6524
|
* Enforce the use of `Math.trunc` instead of bitwise operators.
|
|
6484
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6525
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-math-trunc.md
|
|
6485
6526
|
*/
|
|
6486
6527
|
'unicorn/prefer-math-trunc'?: Linter.RuleEntry<[]>;
|
|
6487
6528
|
/**
|
|
6488
6529
|
* Prefer `.before()` over `.insertBefore()`, `.replaceWith()` over `.replaceChild()`, prefer one of `.before()`, `.after()`, `.append()` or `.prepend()` over `insertAdjacentText()` and `insertAdjacentElement()`.
|
|
6489
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6530
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-modern-dom-apis.md
|
|
6490
6531
|
*/
|
|
6491
6532
|
'unicorn/prefer-modern-dom-apis'?: Linter.RuleEntry<[]>;
|
|
6492
6533
|
/**
|
|
6493
6534
|
* Prefer modern `Math` APIs over legacy patterns.
|
|
6494
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6535
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-modern-math-apis.md
|
|
6495
6536
|
*/
|
|
6496
6537
|
'unicorn/prefer-modern-math-apis'?: Linter.RuleEntry<[]>;
|
|
6497
6538
|
/**
|
|
6498
6539
|
* Prefer JavaScript modules (ESM) over CommonJS.
|
|
6499
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6540
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-module.md
|
|
6500
6541
|
*/
|
|
6501
6542
|
'unicorn/prefer-module'?: Linter.RuleEntry<[]>;
|
|
6502
6543
|
/**
|
|
6503
6544
|
* Prefer using `String`, `Number`, `BigInt`, `Boolean`, and `Symbol` directly.
|
|
6504
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6545
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-native-coercion-functions.md
|
|
6505
6546
|
*/
|
|
6506
6547
|
'unicorn/prefer-native-coercion-functions'?: Linter.RuleEntry<[]>;
|
|
6507
6548
|
/**
|
|
6508
6549
|
* Prefer negative index over `.length - index` when possible.
|
|
6509
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6550
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-negative-index.md
|
|
6510
6551
|
*/
|
|
6511
6552
|
'unicorn/prefer-negative-index'?: Linter.RuleEntry<[]>;
|
|
6512
6553
|
/**
|
|
6513
6554
|
* Prefer using the `node:` protocol when importing Node.js builtin modules.
|
|
6514
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6555
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-node-protocol.md
|
|
6515
6556
|
*/
|
|
6516
6557
|
'unicorn/prefer-node-protocol'?: Linter.RuleEntry<[]>;
|
|
6517
6558
|
/**
|
|
6518
6559
|
* Prefer `Number` static properties over global ones.
|
|
6519
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6560
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-number-properties.md
|
|
6520
6561
|
*/
|
|
6521
6562
|
'unicorn/prefer-number-properties'?: Linter.RuleEntry<UnicornPreferNumberProperties>;
|
|
6522
6563
|
/**
|
|
6523
6564
|
* Prefer using `Object.fromEntries(…)` to transform a list of key-value pairs into an object.
|
|
6524
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6565
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-object-from-entries.md
|
|
6525
6566
|
*/
|
|
6526
6567
|
'unicorn/prefer-object-from-entries'?: Linter.RuleEntry<UnicornPreferObjectFromEntries>;
|
|
6527
6568
|
/**
|
|
6528
6569
|
* Prefer omitting the `catch` binding parameter.
|
|
6529
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6570
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-optional-catch-binding.md
|
|
6530
6571
|
*/
|
|
6531
6572
|
'unicorn/prefer-optional-catch-binding'?: Linter.RuleEntry<[]>;
|
|
6532
6573
|
/**
|
|
6533
6574
|
* Prefer borrowing methods from the prototype instead of the instance.
|
|
6534
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6575
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-prototype-methods.md
|
|
6535
6576
|
*/
|
|
6536
6577
|
'unicorn/prefer-prototype-methods'?: Linter.RuleEntry<[]>;
|
|
6537
6578
|
/**
|
|
6538
6579
|
* Prefer `.querySelector()` over `.getElementById()`, `.querySelectorAll()` over `.getElementsByClassName()` and `.getElementsByTagName()` and `.getElementsByName()`.
|
|
6539
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6580
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-query-selector.md
|
|
6540
6581
|
*/
|
|
6541
6582
|
'unicorn/prefer-query-selector'?: Linter.RuleEntry<[]>;
|
|
6542
6583
|
/**
|
|
6543
6584
|
* Prefer `Reflect.apply()` over `Function#apply()`.
|
|
6544
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6585
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-reflect-apply.md
|
|
6545
6586
|
*/
|
|
6546
6587
|
'unicorn/prefer-reflect-apply'?: Linter.RuleEntry<[]>;
|
|
6547
6588
|
/**
|
|
6548
6589
|
* Prefer `RegExp#test()` over `String#match()` and `RegExp#exec()`.
|
|
6549
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6590
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-regexp-test.md
|
|
6550
6591
|
*/
|
|
6551
6592
|
'unicorn/prefer-regexp-test'?: Linter.RuleEntry<[]>;
|
|
6552
6593
|
/**
|
|
6553
6594
|
* Prefer `Set#has()` over `Array#includes()` when checking for existence or non-existence.
|
|
6554
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6595
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-set-has.md
|
|
6555
6596
|
*/
|
|
6556
6597
|
'unicorn/prefer-set-has'?: Linter.RuleEntry<[]>;
|
|
6557
6598
|
/**
|
|
6558
6599
|
* Prefer using `Set#size` instead of `Array#length`.
|
|
6559
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6600
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-set-size.md
|
|
6560
6601
|
*/
|
|
6561
6602
|
'unicorn/prefer-set-size'?: Linter.RuleEntry<[]>;
|
|
6562
6603
|
/**
|
|
6563
6604
|
* Enforce combining multiple `Array#push()`, `Element#classList.{add,remove}()`, and `importScripts()` into one call.
|
|
6564
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6605
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-single-call.md
|
|
6565
6606
|
*/
|
|
6566
6607
|
'unicorn/prefer-single-call'?: Linter.RuleEntry<UnicornPreferSingleCall>;
|
|
6567
6608
|
/**
|
|
6568
6609
|
* Prefer the spread operator over `Array.from(…)`, `Array#concat(…)`, `Array#{slice,toSpliced}()` and `String#split('')`.
|
|
6569
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6610
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-spread.md
|
|
6570
6611
|
*/
|
|
6571
6612
|
'unicorn/prefer-spread'?: Linter.RuleEntry<[]>;
|
|
6572
6613
|
/**
|
|
6573
6614
|
* Prefer using the `String.raw` tag to avoid escaping `\`.
|
|
6574
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6615
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-string-raw.md
|
|
6575
6616
|
*/
|
|
6576
6617
|
'unicorn/prefer-string-raw'?: Linter.RuleEntry<[]>;
|
|
6577
6618
|
/**
|
|
6578
6619
|
* Prefer `String#replaceAll()` over regex searches with the global flag.
|
|
6579
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6620
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-string-replace-all.md
|
|
6580
6621
|
*/
|
|
6581
6622
|
'unicorn/prefer-string-replace-all'?: Linter.RuleEntry<[]>;
|
|
6582
6623
|
/**
|
|
6583
6624
|
* Prefer `String#slice()` over `String#substr()` and `String#substring()`.
|
|
6584
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6625
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-string-slice.md
|
|
6585
6626
|
*/
|
|
6586
6627
|
'unicorn/prefer-string-slice'?: Linter.RuleEntry<[]>;
|
|
6587
6628
|
/**
|
|
6588
6629
|
* Prefer `String#startsWith()` & `String#endsWith()` over `RegExp#test()`.
|
|
6589
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6630
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-string-starts-ends-with.md
|
|
6590
6631
|
*/
|
|
6591
6632
|
'unicorn/prefer-string-starts-ends-with'?: Linter.RuleEntry<[]>;
|
|
6592
6633
|
/**
|
|
6593
6634
|
* Prefer `String#trimStart()` / `String#trimEnd()` over `String#trimLeft()` / `String#trimRight()`.
|
|
6594
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6635
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-string-trim-start-end.md
|
|
6595
6636
|
*/
|
|
6596
6637
|
'unicorn/prefer-string-trim-start-end'?: Linter.RuleEntry<[]>;
|
|
6597
6638
|
/**
|
|
6598
6639
|
* Prefer using `structuredClone` to create a deep clone.
|
|
6599
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6640
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-structured-clone.md
|
|
6600
6641
|
*/
|
|
6601
6642
|
'unicorn/prefer-structured-clone'?: Linter.RuleEntry<UnicornPreferStructuredClone>;
|
|
6602
6643
|
/**
|
|
6603
6644
|
* Prefer `switch` over multiple `else-if`.
|
|
6604
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6645
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-switch.md
|
|
6605
6646
|
*/
|
|
6606
6647
|
'unicorn/prefer-switch'?: Linter.RuleEntry<UnicornPreferSwitch>;
|
|
6607
6648
|
/**
|
|
6608
6649
|
* Prefer ternary expressions over simple `if-else` statements.
|
|
6609
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6650
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-ternary.md
|
|
6610
6651
|
*/
|
|
6611
6652
|
'unicorn/prefer-ternary'?: Linter.RuleEntry<UnicornPreferTernary>;
|
|
6612
6653
|
/**
|
|
6613
6654
|
* Prefer top-level await over top-level promises and async function calls.
|
|
6614
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6655
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-top-level-await.md
|
|
6615
6656
|
*/
|
|
6616
6657
|
'unicorn/prefer-top-level-await'?: Linter.RuleEntry<[]>;
|
|
6617
6658
|
/**
|
|
6618
6659
|
* Enforce throwing `TypeError` in type checking conditions.
|
|
6619
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6660
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prefer-type-error.md
|
|
6620
6661
|
*/
|
|
6621
6662
|
'unicorn/prefer-type-error'?: Linter.RuleEntry<[]>;
|
|
6622
6663
|
/**
|
|
6623
6664
|
* Prevent abbreviations.
|
|
6624
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6665
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/prevent-abbreviations.md
|
|
6625
6666
|
*/
|
|
6626
6667
|
'unicorn/prevent-abbreviations'?: Linter.RuleEntry<UnicornPreventAbbreviations>;
|
|
6627
6668
|
/**
|
|
6628
6669
|
* Enforce consistent relative URL style.
|
|
6629
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6670
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/relative-url-style.md
|
|
6630
6671
|
*/
|
|
6631
6672
|
'unicorn/relative-url-style'?: Linter.RuleEntry<UnicornRelativeUrlStyle>;
|
|
6632
6673
|
/**
|
|
6633
6674
|
* Enforce using the separator argument with `Array#join()`.
|
|
6634
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6675
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/require-array-join-separator.md
|
|
6635
6676
|
*/
|
|
6636
6677
|
'unicorn/require-array-join-separator'?: Linter.RuleEntry<[]>;
|
|
6678
|
+
/**
|
|
6679
|
+
* Require non-empty module attributes for imports and exports
|
|
6680
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/require-module-attributes.md
|
|
6681
|
+
*/
|
|
6682
|
+
'unicorn/require-module-attributes'?: Linter.RuleEntry<[]>;
|
|
6637
6683
|
/**
|
|
6638
6684
|
* Require non-empty specifier list in import and export statements.
|
|
6639
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6685
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/require-module-specifiers.md
|
|
6640
6686
|
*/
|
|
6641
6687
|
'unicorn/require-module-specifiers'?: Linter.RuleEntry<[]>;
|
|
6642
6688
|
/**
|
|
6643
6689
|
* Enforce using the digits argument with `Number#toFixed()`.
|
|
6644
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6690
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/require-number-to-fixed-digits-argument.md
|
|
6645
6691
|
*/
|
|
6646
6692
|
'unicorn/require-number-to-fixed-digits-argument'?: Linter.RuleEntry<[]>;
|
|
6647
6693
|
/**
|
|
6648
6694
|
* Enforce using the `targetOrigin` argument with `window.postMessage()`.
|
|
6649
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6695
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/require-post-message-target-origin.md
|
|
6650
6696
|
*/
|
|
6651
6697
|
'unicorn/require-post-message-target-origin'?: Linter.RuleEntry<[]>;
|
|
6652
6698
|
/**
|
|
6653
6699
|
* Enforce better string content.
|
|
6654
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6700
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/string-content.md
|
|
6655
6701
|
*/
|
|
6656
6702
|
'unicorn/string-content'?: Linter.RuleEntry<UnicornStringContent>;
|
|
6657
6703
|
/**
|
|
6658
6704
|
* Enforce consistent brace style for `case` clauses.
|
|
6659
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6705
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/switch-case-braces.md
|
|
6660
6706
|
*/
|
|
6661
6707
|
'unicorn/switch-case-braces'?: Linter.RuleEntry<UnicornSwitchCaseBraces>;
|
|
6662
6708
|
/**
|
|
6663
6709
|
* Fix whitespace-insensitive template indentation.
|
|
6664
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6710
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/template-indent.md
|
|
6665
6711
|
*/
|
|
6666
6712
|
'unicorn/template-indent'?: Linter.RuleEntry<UnicornTemplateIndent>;
|
|
6667
6713
|
/**
|
|
6668
6714
|
* Enforce consistent case for text encoding identifiers.
|
|
6669
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6715
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/text-encoding-identifier-case.md
|
|
6670
6716
|
*/
|
|
6671
6717
|
'unicorn/text-encoding-identifier-case'?: Linter.RuleEntry<[]>;
|
|
6672
6718
|
/**
|
|
6673
6719
|
* Require `new` when creating an error.
|
|
6674
|
-
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/
|
|
6720
|
+
* @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v61.0.2/docs/rules/throw-new-error.md
|
|
6675
6721
|
*/
|
|
6676
6722
|
'unicorn/throw-new-error'?: Linter.RuleEntry<[]>;
|
|
6677
6723
|
/**
|
|
@@ -8122,7 +8168,6 @@ interface RuleOptions {
|
|
|
8122
8168
|
*/
|
|
8123
8169
|
'yoda'?: Linter.RuleEntry<Yoda>;
|
|
8124
8170
|
}
|
|
8125
|
-
|
|
8126
8171
|
/* ======= Declarations ======= */
|
|
8127
8172
|
// ----- accessor-pairs -----
|
|
8128
8173
|
type AccessorPairs = [] | [{
|
|
@@ -8499,6 +8544,10 @@ type IndentLegacy = [] | [("tab" | number)] | [("tab" | number), {
|
|
|
8499
8544
|
type InitDeclarations = ([] | ["always"] | [] | ["never"] | ["never", {
|
|
8500
8545
|
ignoreForLoopInit?: boolean;
|
|
8501
8546
|
}]);
|
|
8547
|
+
// ----- jsdoc/check-alignment -----
|
|
8548
|
+
type JsdocCheckAlignment = [] | [{
|
|
8549
|
+
innerIndent?: number;
|
|
8550
|
+
}];
|
|
8502
8551
|
// ----- jsdoc/check-examples -----
|
|
8503
8552
|
type JsdocCheckExamples = [] | [{
|
|
8504
8553
|
allowInlineConfig?: boolean;
|
|
@@ -8788,6 +8837,7 @@ type JsdocRequireJsdoc = [] | [{
|
|
|
8788
8837
|
enableFixer?: boolean;
|
|
8789
8838
|
exemptEmptyConstructors?: boolean;
|
|
8790
8839
|
exemptEmptyFunctions?: boolean;
|
|
8840
|
+
exemptOverloadedImplementations?: boolean;
|
|
8791
8841
|
fixerMessage?: string;
|
|
8792
8842
|
minLineCount?: number;
|
|
8793
8843
|
publicOnly?: (boolean | {
|
|
@@ -8804,6 +8854,7 @@ type JsdocRequireJsdoc = [] | [{
|
|
|
8804
8854
|
FunctionExpression?: boolean;
|
|
8805
8855
|
MethodDefinition?: boolean;
|
|
8806
8856
|
};
|
|
8857
|
+
skipInterveningOverloadedDeclarations?: boolean;
|
|
8807
8858
|
}];
|
|
8808
8859
|
// ----- jsdoc/require-param -----
|
|
8809
8860
|
type JsdocRequireParam = [] | [{
|
|
@@ -8894,6 +8945,7 @@ type JsdocRequireReturnsType = [] | [{
|
|
|
8894
8945
|
}];
|
|
8895
8946
|
// ----- jsdoc/require-template -----
|
|
8896
8947
|
type JsdocRequireTemplate = [] | [{
|
|
8948
|
+
exemptedBy?: string[];
|
|
8897
8949
|
requireSeparateTemplates?: boolean;
|
|
8898
8950
|
}];
|
|
8899
8951
|
// ----- jsdoc/require-throws -----
|
|
@@ -8955,6 +9007,21 @@ type JsdocTextEscaping = [] | [{
|
|
|
8955
9007
|
escapeHTML?: boolean;
|
|
8956
9008
|
escapeMarkdown?: boolean;
|
|
8957
9009
|
}];
|
|
9010
|
+
// ----- jsdoc/type-formatting -----
|
|
9011
|
+
type JsdocTypeFormatting = [] | [{
|
|
9012
|
+
arrayBrackets?: ("angle" | "square");
|
|
9013
|
+
enableFixer?: boolean;
|
|
9014
|
+
genericDot?: boolean;
|
|
9015
|
+
objectFieldIndent?: string;
|
|
9016
|
+
objectFieldQuote?: ("double" | "single" | null);
|
|
9017
|
+
objectFieldSeparator?: ("comma" | "comma-and-linebreak" | "linebreak" | "semicolon" | "semicolon-and-linebreak");
|
|
9018
|
+
objectFieldSeparatorTrailingPunctuation?: boolean;
|
|
9019
|
+
propertyQuotes?: ("double" | "single" | null);
|
|
9020
|
+
separatorForSingleObjectField?: boolean;
|
|
9021
|
+
stringQuotes?: ("double" | "single");
|
|
9022
|
+
typeBracketSpacing?: string;
|
|
9023
|
+
unionSpacing?: string;
|
|
9024
|
+
}];
|
|
8958
9025
|
// ----- jsdoc/valid-types -----
|
|
8959
9026
|
type JsdocValidTypes = [] | [{
|
|
8960
9027
|
allowEmptyNamepaths?: boolean;
|
|
@@ -9615,6 +9682,10 @@ type LogicalAssignmentOperators = (([] | ["always"] | ["always", {
|
|
|
9615
9682
|
type MarkdownFencedCodeLanguage = [] | [{
|
|
9616
9683
|
required?: string[];
|
|
9617
9684
|
}];
|
|
9685
|
+
// ----- markdown/heading-increment -----
|
|
9686
|
+
type MarkdownHeadingIncrement = [] | [{
|
|
9687
|
+
frontmatterTitle?: string;
|
|
9688
|
+
}];
|
|
9618
9689
|
// ----- markdown/no-duplicate-definitions -----
|
|
9619
9690
|
type MarkdownNoDuplicateDefinitions = [] | [{
|
|
9620
9691
|
allowDefinitions?: string[];
|
|
@@ -9633,6 +9704,11 @@ type MarkdownNoEmptyDefinitions = [] | [{
|
|
|
9633
9704
|
// ----- markdown/no-html -----
|
|
9634
9705
|
type MarkdownNoHtml = [] | [{
|
|
9635
9706
|
allowed?: string[];
|
|
9707
|
+
allowedIgnoreCase?: boolean;
|
|
9708
|
+
}];
|
|
9709
|
+
// ----- markdown/no-missing-atx-heading-space -----
|
|
9710
|
+
type MarkdownNoMissingAtxHeadingSpace = [] | [{
|
|
9711
|
+
checkClosedHeadings?: boolean;
|
|
9636
9712
|
}];
|
|
9637
9713
|
// ----- markdown/no-missing-link-fragments -----
|
|
9638
9714
|
type MarkdownNoMissingLinkFragments = [] | [{
|
|
@@ -9643,6 +9719,10 @@ type MarkdownNoMissingLinkFragments = [] | [{
|
|
|
9643
9719
|
type MarkdownNoMultipleH1 = [] | [{
|
|
9644
9720
|
frontmatterTitle?: string;
|
|
9645
9721
|
}];
|
|
9722
|
+
// ----- markdown/no-space-in-emphasis -----
|
|
9723
|
+
type MarkdownNoSpaceInEmphasis = [] | [{
|
|
9724
|
+
checkStrikethrough?: boolean;
|
|
9725
|
+
}];
|
|
9646
9726
|
// ----- markdown/no-unused-definitions -----
|
|
9647
9727
|
type MarkdownNoUnusedDefinitions = [] | [{
|
|
9648
9728
|
allowDefinitions?: string[];
|
|
@@ -12326,6 +12406,10 @@ type PreferReflect = [] | [{
|
|
|
12326
12406
|
type PreferRegexLiterals = [] | [{
|
|
12327
12407
|
disallowRedundantWrapping?: boolean;
|
|
12328
12408
|
}];
|
|
12409
|
+
// ----- preserve-caught-error -----
|
|
12410
|
+
type PreserveCaughtError = [] | [{
|
|
12411
|
+
requireCatchParameter?: boolean;
|
|
12412
|
+
}];
|
|
12329
12413
|
// ----- quote-props -----
|
|
12330
12414
|
type QuoteProps = ([] | [("always" | "as-needed" | "consistent" | "consistent-as-needed")] | [] | [("always" | "as-needed" | "consistent" | "consistent-as-needed")] | [("always" | "as-needed" | "consistent" | "consistent-as-needed"), {
|
|
12331
12415
|
keywords?: boolean;
|
|
@@ -12352,8 +12436,6 @@ type ReactHooksExhaustiveDeps = [] | [{
|
|
|
12352
12436
|
// ----- react-naming-convention/component-name -----
|
|
12353
12437
|
type ReactNamingConventionComponentName = [] | [(("PascalCase" | "CONSTANT_CASE") | {
|
|
12354
12438
|
allowAllCaps?: boolean;
|
|
12355
|
-
allowLeadingUnderscore?: boolean;
|
|
12356
|
-
allowNamespace?: boolean;
|
|
12357
12439
|
excepts?: string[];
|
|
12358
12440
|
rule?: ("PascalCase" | "CONSTANT_CASE");
|
|
12359
12441
|
})];
|
|
@@ -12812,6 +12894,7 @@ type StyleIndent = [] | [("tab" | number)] | [("tab" | number), {
|
|
|
12812
12894
|
const?: (number | ("first" | "off"));
|
|
12813
12895
|
using?: (number | ("first" | "off"));
|
|
12814
12896
|
});
|
|
12897
|
+
assignmentOperator?: (number | "off");
|
|
12815
12898
|
outerIIFEBody?: (number | "off");
|
|
12816
12899
|
MemberExpression?: (number | "off");
|
|
12817
12900
|
FunctionDeclaration?: {
|
|
@@ -13044,6 +13127,22 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13044
13127
|
before?: boolean;
|
|
13045
13128
|
after?: boolean;
|
|
13046
13129
|
};
|
|
13130
|
+
arguments?: {
|
|
13131
|
+
before?: boolean;
|
|
13132
|
+
after?: boolean;
|
|
13133
|
+
};
|
|
13134
|
+
as?: {
|
|
13135
|
+
before?: boolean;
|
|
13136
|
+
after?: boolean;
|
|
13137
|
+
};
|
|
13138
|
+
async?: {
|
|
13139
|
+
before?: boolean;
|
|
13140
|
+
after?: boolean;
|
|
13141
|
+
};
|
|
13142
|
+
await?: {
|
|
13143
|
+
before?: boolean;
|
|
13144
|
+
after?: boolean;
|
|
13145
|
+
};
|
|
13047
13146
|
boolean?: {
|
|
13048
13147
|
before?: boolean;
|
|
13049
13148
|
after?: boolean;
|
|
@@ -13108,6 +13207,10 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13108
13207
|
before?: boolean;
|
|
13109
13208
|
after?: boolean;
|
|
13110
13209
|
};
|
|
13210
|
+
eval?: {
|
|
13211
|
+
before?: boolean;
|
|
13212
|
+
after?: boolean;
|
|
13213
|
+
};
|
|
13111
13214
|
export?: {
|
|
13112
13215
|
before?: boolean;
|
|
13113
13216
|
after?: boolean;
|
|
@@ -13136,10 +13239,18 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13136
13239
|
before?: boolean;
|
|
13137
13240
|
after?: boolean;
|
|
13138
13241
|
};
|
|
13242
|
+
from?: {
|
|
13243
|
+
before?: boolean;
|
|
13244
|
+
after?: boolean;
|
|
13245
|
+
};
|
|
13139
13246
|
function?: {
|
|
13140
13247
|
before?: boolean;
|
|
13141
13248
|
after?: boolean;
|
|
13142
13249
|
};
|
|
13250
|
+
get?: {
|
|
13251
|
+
before?: boolean;
|
|
13252
|
+
after?: boolean;
|
|
13253
|
+
};
|
|
13143
13254
|
goto?: {
|
|
13144
13255
|
before?: boolean;
|
|
13145
13256
|
after?: boolean;
|
|
@@ -13172,6 +13283,10 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13172
13283
|
before?: boolean;
|
|
13173
13284
|
after?: boolean;
|
|
13174
13285
|
};
|
|
13286
|
+
let?: {
|
|
13287
|
+
before?: boolean;
|
|
13288
|
+
after?: boolean;
|
|
13289
|
+
};
|
|
13175
13290
|
long?: {
|
|
13176
13291
|
before?: boolean;
|
|
13177
13292
|
after?: boolean;
|
|
@@ -13188,6 +13303,10 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13188
13303
|
before?: boolean;
|
|
13189
13304
|
after?: boolean;
|
|
13190
13305
|
};
|
|
13306
|
+
of?: {
|
|
13307
|
+
before?: boolean;
|
|
13308
|
+
after?: boolean;
|
|
13309
|
+
};
|
|
13191
13310
|
package?: {
|
|
13192
13311
|
before?: boolean;
|
|
13193
13312
|
after?: boolean;
|
|
@@ -13208,6 +13327,10 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13208
13327
|
before?: boolean;
|
|
13209
13328
|
after?: boolean;
|
|
13210
13329
|
};
|
|
13330
|
+
set?: {
|
|
13331
|
+
before?: boolean;
|
|
13332
|
+
after?: boolean;
|
|
13333
|
+
};
|
|
13211
13334
|
short?: {
|
|
13212
13335
|
before?: boolean;
|
|
13213
13336
|
after?: boolean;
|
|
@@ -13252,59 +13375,43 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13252
13375
|
before?: boolean;
|
|
13253
13376
|
after?: boolean;
|
|
13254
13377
|
};
|
|
13255
|
-
|
|
13256
|
-
before?: boolean;
|
|
13257
|
-
after?: boolean;
|
|
13258
|
-
};
|
|
13259
|
-
var?: {
|
|
13260
|
-
before?: boolean;
|
|
13261
|
-
after?: boolean;
|
|
13262
|
-
};
|
|
13263
|
-
void?: {
|
|
13264
|
-
before?: boolean;
|
|
13265
|
-
after?: boolean;
|
|
13266
|
-
};
|
|
13267
|
-
volatile?: {
|
|
13268
|
-
before?: boolean;
|
|
13269
|
-
after?: boolean;
|
|
13270
|
-
};
|
|
13271
|
-
while?: {
|
|
13378
|
+
type?: {
|
|
13272
13379
|
before?: boolean;
|
|
13273
13380
|
after?: boolean;
|
|
13274
13381
|
};
|
|
13275
|
-
|
|
13382
|
+
typeof?: {
|
|
13276
13383
|
before?: boolean;
|
|
13277
13384
|
after?: boolean;
|
|
13278
13385
|
};
|
|
13279
|
-
|
|
13386
|
+
using?: {
|
|
13280
13387
|
before?: boolean;
|
|
13281
13388
|
after?: boolean;
|
|
13282
13389
|
};
|
|
13283
|
-
|
|
13390
|
+
var?: {
|
|
13284
13391
|
before?: boolean;
|
|
13285
13392
|
after?: boolean;
|
|
13286
13393
|
};
|
|
13287
|
-
|
|
13394
|
+
void?: {
|
|
13288
13395
|
before?: boolean;
|
|
13289
13396
|
after?: boolean;
|
|
13290
13397
|
};
|
|
13291
|
-
|
|
13398
|
+
volatile?: {
|
|
13292
13399
|
before?: boolean;
|
|
13293
13400
|
after?: boolean;
|
|
13294
13401
|
};
|
|
13295
|
-
|
|
13402
|
+
while?: {
|
|
13296
13403
|
before?: boolean;
|
|
13297
13404
|
after?: boolean;
|
|
13298
13405
|
};
|
|
13299
|
-
|
|
13406
|
+
with?: {
|
|
13300
13407
|
before?: boolean;
|
|
13301
13408
|
after?: boolean;
|
|
13302
13409
|
};
|
|
13303
|
-
|
|
13410
|
+
yield?: {
|
|
13304
13411
|
before?: boolean;
|
|
13305
13412
|
after?: boolean;
|
|
13306
13413
|
};
|
|
13307
|
-
|
|
13414
|
+
accessor?: {
|
|
13308
13415
|
before?: boolean;
|
|
13309
13416
|
after?: boolean;
|
|
13310
13417
|
};
|
|
@@ -13312,22 +13419,6 @@ type StyleKeywordSpacing = [] | [{
|
|
|
13312
13419
|
before?: boolean;
|
|
13313
13420
|
after?: boolean;
|
|
13314
13421
|
};
|
|
13315
|
-
set?: {
|
|
13316
|
-
before?: boolean;
|
|
13317
|
-
after?: boolean;
|
|
13318
|
-
};
|
|
13319
|
-
using?: {
|
|
13320
|
-
before?: boolean;
|
|
13321
|
-
after?: boolean;
|
|
13322
|
-
};
|
|
13323
|
-
yield?: {
|
|
13324
|
-
before?: boolean;
|
|
13325
|
-
after?: boolean;
|
|
13326
|
-
};
|
|
13327
|
-
type?: {
|
|
13328
|
-
before?: boolean;
|
|
13329
|
-
after?: boolean;
|
|
13330
|
-
};
|
|
13331
13422
|
};
|
|
13332
13423
|
}];
|
|
13333
13424
|
// ----- style/line-comment-position -----
|
|
@@ -13527,6 +13618,7 @@ type StyleNoExtraParens = ([] | ["functions"] | [] | ["all"] | ["all", {
|
|
|
13527
13618
|
LogicalExpression?: boolean;
|
|
13528
13619
|
AwaitExpression?: boolean;
|
|
13529
13620
|
};
|
|
13621
|
+
ignoredNodes?: string[];
|
|
13530
13622
|
}]);
|
|
13531
13623
|
// ----- style/no-mixed-operators -----
|
|
13532
13624
|
type StyleNoMixedOperators = [] | [{
|
|
@@ -13642,7 +13734,7 @@ type StylePaddedBlocks = [] | [(("always" | "never" | "start" | "end") | {
|
|
|
13642
13734
|
// ----- style/padding-line-between-statements -----
|
|
13643
13735
|
type _StylePaddingLineBetweenStatementsPaddingType = ("any" | "never" | "always");
|
|
13644
13736
|
type _StylePaddingLineBetweenStatementsStatementOption = (_StylePaddingLineBetweenStatementsStatementType | [_StylePaddingLineBetweenStatementsStatementType, ...(_StylePaddingLineBetweenStatementsStatementType)[]]);
|
|
13645
|
-
type _StylePaddingLineBetweenStatementsStatementType = ("*" | "exports" | "require" | "directive" | "iife" | "block" | "empty" | "function" | "ts-method" | "break" | "case" | "class" | "continue" | "debugger" | "default" | "do" | "for" | "if" | "import" | "
|
|
13737
|
+
type _StylePaddingLineBetweenStatementsStatementType = ("*" | "exports" | "require" | "directive" | "iife" | "block" | "empty" | "function" | "ts-method" | "break" | "case" | "class" | "continue" | "debugger" | "default" | "do" | "for" | "if" | "import" | "switch" | "throw" | "try" | "while" | "with" | "cjs-export" | "cjs-import" | "enum" | "interface" | "function-overload" | "block-like" | "singleline-block-like" | "multiline-block-like" | "expression" | "singleline-expression" | "multiline-expression" | "return" | "singleline-return" | "multiline-return" | "export" | "singleline-export" | "multiline-export" | "var" | "singleline-var" | "multiline-var" | "let" | "singleline-let" | "multiline-let" | "const" | "singleline-const" | "multiline-const" | "using" | "singleline-using" | "multiline-using" | "type" | "singleline-type" | "multiline-type");
|
|
13646
13738
|
type StylePaddingLineBetweenStatements = {
|
|
13647
13739
|
blankLine: _StylePaddingLineBetweenStatementsPaddingType;
|
|
13648
13740
|
prev: _StylePaddingLineBetweenStatementsStatementOption;
|
|
@@ -15083,6 +15175,10 @@ type UnicornNoArrayReduce = [] | [{
|
|
|
15083
15175
|
type UnicornNoArrayReverse = [] | [{
|
|
15084
15176
|
allowExpressionStatement?: boolean;
|
|
15085
15177
|
}];
|
|
15178
|
+
// ----- unicorn/no-array-sort -----
|
|
15179
|
+
type UnicornNoArraySort = [] | [{
|
|
15180
|
+
allowExpressionStatement?: boolean;
|
|
15181
|
+
}];
|
|
15086
15182
|
// ----- unicorn/no-instanceof-builtins -----
|
|
15087
15183
|
type UnicornNoInstanceofBuiltins = [] | [{
|
|
15088
15184
|
useErrorIsError?: boolean;
|
|
@@ -15240,7 +15336,6 @@ type UnocssEnforceClassCompile = [] | [{
|
|
|
15240
15336
|
type UnocssOrder = [] | [{
|
|
15241
15337
|
unoFunctions?: string[];
|
|
15242
15338
|
unoVariables?: string[];
|
|
15243
|
-
[k: string]: unknown | undefined;
|
|
15244
15339
|
}];
|
|
15245
15340
|
// ----- unused-imports/no-unused-imports -----
|
|
15246
15341
|
type UnusedImportsNoUnusedImports = [] | [(("all" | "local") | {
|