@w5s/eslint-config 3.3.2 → 3.3.4

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.
@@ -11,725 +11,690 @@ declare module 'eslint' {
11
11
  export interface RuleOptions {
12
12
  /**
13
13
  * Improve regexes by making them shorter, consistent, and safer.
14
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/better-regex.md
14
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/better-regex.md
15
15
  */
16
16
  'unicorn/better-regex'?: Linter.RuleEntry<UnicornBetterRegex>
17
17
  /**
18
18
  * Enforce a specific parameter name in catch clauses.
19
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/catch-error-name.md
19
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/catch-error-name.md
20
20
  */
21
21
  'unicorn/catch-error-name'?: Linter.RuleEntry<UnicornCatchErrorName>
22
22
  /**
23
23
  * Enforce consistent assertion style with `node:assert`.
24
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-assert.md
24
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/consistent-assert.md
25
25
  */
26
26
  'unicorn/consistent-assert'?: Linter.RuleEntry<[]>
27
27
  /**
28
28
  * Prefer passing `Date` directly to the constructor when cloning.
29
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-date-clone.md
29
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/consistent-date-clone.md
30
30
  */
31
31
  'unicorn/consistent-date-clone'?: Linter.RuleEntry<[]>
32
32
  /**
33
33
  * Use destructured variables over properties.
34
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-destructuring.md
34
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/consistent-destructuring.md
35
35
  */
36
36
  'unicorn/consistent-destructuring'?: Linter.RuleEntry<[]>
37
37
  /**
38
38
  * Prefer consistent types when spreading a ternary in an array literal.
39
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-empty-array-spread.md
39
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/consistent-empty-array-spread.md
40
40
  */
41
41
  'unicorn/consistent-empty-array-spread'?: Linter.RuleEntry<[]>
42
42
  /**
43
43
  * Enforce consistent style for element existence checks with `indexOf()`, `lastIndexOf()`, `findIndex()`, and `findLastIndex()`.
44
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-existence-index-check.md
44
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/consistent-existence-index-check.md
45
45
  */
46
46
  'unicorn/consistent-existence-index-check'?: Linter.RuleEntry<[]>
47
47
  /**
48
48
  * Move function definitions to the highest possible scope.
49
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/consistent-function-scoping.md
49
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/consistent-function-scoping.md
50
50
  */
51
51
  'unicorn/consistent-function-scoping'?: Linter.RuleEntry<UnicornConsistentFunctionScoping>
52
52
  /**
53
53
  * Enforce correct `Error` subclassing.
54
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/custom-error-definition.md
54
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/custom-error-definition.md
55
55
  */
56
56
  'unicorn/custom-error-definition'?: Linter.RuleEntry<[]>
57
57
  /**
58
58
  * Enforce no spaces between braces.
59
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/empty-brace-spaces.md
59
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/empty-brace-spaces.md
60
60
  */
61
61
  'unicorn/empty-brace-spaces'?: Linter.RuleEntry<[]>
62
62
  /**
63
63
  * Enforce passing a `message` value when creating a built-in error.
64
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/error-message.md
64
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/error-message.md
65
65
  */
66
66
  'unicorn/error-message'?: Linter.RuleEntry<[]>
67
67
  /**
68
68
  * Require escape sequences to use uppercase or lowercase values.
69
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/escape-case.md
69
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/escape-case.md
70
70
  */
71
71
  'unicorn/escape-case'?: Linter.RuleEntry<UnicornEscapeCase>
72
72
  /**
73
73
  * Add expiration conditions to TODO comments.
74
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/expiring-todo-comments.md
74
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/expiring-todo-comments.md
75
75
  */
76
76
  'unicorn/expiring-todo-comments'?: Linter.RuleEntry<UnicornExpiringTodoComments>
77
77
  /**
78
78
  * Enforce explicitly comparing the `length` or `size` property of a value.
79
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/explicit-length-check.md
79
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/explicit-length-check.md
80
80
  */
81
81
  'unicorn/explicit-length-check'?: Linter.RuleEntry<UnicornExplicitLengthCheck>
82
82
  /**
83
83
  * Enforce a case style for filenames.
84
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/filename-case.md
84
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/filename-case.md
85
85
  */
86
86
  'unicorn/filename-case'?: Linter.RuleEntry<UnicornFilenameCase>
87
87
  /**
88
88
  * Enforce specific import styles per module.
89
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/import-style.md
89
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/import-style.md
90
90
  */
91
91
  'unicorn/import-style'?: Linter.RuleEntry<UnicornImportStyle>
92
92
  /**
93
93
  * Enforce the use of `new` for all builtins, except `String`, `Number`, `Boolean`, `Symbol` and `BigInt`.
94
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/new-for-builtins.md
94
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/new-for-builtins.md
95
95
  */
96
96
  'unicorn/new-for-builtins'?: Linter.RuleEntry<[]>
97
97
  /**
98
98
  * Enforce specifying rules to disable in `eslint-disable` comments.
99
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-abusive-eslint-disable.md
99
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-abusive-eslint-disable.md
100
100
  */
101
101
  'unicorn/no-abusive-eslint-disable'?: Linter.RuleEntry<[]>
102
102
  /**
103
103
  * Disallow recursive access to `this` within getters and setters.
104
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-accessor-recursion.md
104
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-accessor-recursion.md
105
105
  */
106
106
  'unicorn/no-accessor-recursion'?: Linter.RuleEntry<[]>
107
107
  /**
108
108
  * Disallow anonymous functions and classes as the default export.
109
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-anonymous-default-export.md
109
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-anonymous-default-export.md
110
110
  */
111
111
  'unicorn/no-anonymous-default-export'?: Linter.RuleEntry<[]>
112
112
  /**
113
113
  * Prevent passing a function reference directly to iterator methods.
114
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-callback-reference.md
114
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-array-callback-reference.md
115
115
  */
116
116
  'unicorn/no-array-callback-reference'?: Linter.RuleEntry<[]>
117
117
  /**
118
118
  * Prefer `for…of` over the `forEach` method.
119
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-for-each.md
119
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-array-for-each.md
120
120
  */
121
121
  'unicorn/no-array-for-each'?: Linter.RuleEntry<[]>
122
122
  /**
123
123
  * Disallow using the `this` argument in array methods.
124
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-method-this-argument.md
124
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-array-method-this-argument.md
125
125
  */
126
126
  'unicorn/no-array-method-this-argument'?: Linter.RuleEntry<[]>
127
127
  /**
128
128
  * Replaced by `unicorn/prefer-single-call` which covers more cases.
129
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/deprecated-rules.md#no-array-push-push
129
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/deprecated-rules.md#no-array-push-push
130
130
  * @deprecated
131
131
  */
132
132
  'unicorn/no-array-push-push'?: Linter.RuleEntry<[]>
133
133
  /**
134
134
  * Disallow `Array#reduce()` and `Array#reduceRight()`.
135
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-reduce.md
135
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-array-reduce.md
136
136
  */
137
137
  'unicorn/no-array-reduce'?: Linter.RuleEntry<UnicornNoArrayReduce>
138
138
  /**
139
139
  * Prefer `Array#toReversed()` over `Array#reverse()`.
140
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-reverse.md
140
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-array-reverse.md
141
141
  */
142
142
  'unicorn/no-array-reverse'?: Linter.RuleEntry<UnicornNoArrayReverse>
143
- /**
144
- * Prefer `Array#toSorted()` over `Array#sort()`.
145
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-array-sort.md
146
- */
147
- 'unicorn/no-array-sort'?: Linter.RuleEntry<UnicornNoArraySort>
148
143
  /**
149
144
  * Disallow member access from await expression.
150
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-await-expression-member.md
145
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-await-expression-member.md
151
146
  */
152
147
  'unicorn/no-await-expression-member'?: Linter.RuleEntry<[]>
153
148
  /**
154
149
  * Disallow using `await` in `Promise` method parameters.
155
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-await-in-promise-methods.md
150
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-await-in-promise-methods.md
156
151
  */
157
152
  'unicorn/no-await-in-promise-methods'?: Linter.RuleEntry<[]>
158
153
  /**
159
154
  * Do not use leading/trailing space between `console.log` parameters.
160
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-console-spaces.md
155
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-console-spaces.md
161
156
  */
162
157
  'unicorn/no-console-spaces'?: Linter.RuleEntry<[]>
163
158
  /**
164
159
  * Do not use `document.cookie` directly.
165
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-document-cookie.md
160
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-document-cookie.md
166
161
  */
167
162
  'unicorn/no-document-cookie'?: Linter.RuleEntry<[]>
168
163
  /**
169
164
  * Disallow empty files.
170
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-empty-file.md
165
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-empty-file.md
171
166
  */
172
167
  'unicorn/no-empty-file'?: Linter.RuleEntry<[]>
173
168
  /**
174
169
  * Do not use a `for` loop that can be replaced with a `for-of` loop.
175
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-for-loop.md
170
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-for-loop.md
176
171
  */
177
172
  'unicorn/no-for-loop'?: Linter.RuleEntry<[]>
178
173
  /**
179
174
  * Enforce the use of Unicode escapes instead of hexadecimal escapes.
180
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-hex-escape.md
175
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-hex-escape.md
181
176
  */
182
177
  'unicorn/no-hex-escape'?: Linter.RuleEntry<[]>
183
- /**
184
- * Disallow immediate mutation after variable assignment.
185
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-immediate-mutation.md
186
- */
187
- 'unicorn/no-immediate-mutation'?: Linter.RuleEntry<[]>
188
178
  /**
189
179
  * Replaced by `unicorn/no-instanceof-builtins` which covers more cases.
190
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/deprecated-rules.md#no-instanceof-array
180
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/deprecated-rules.md#no-instanceof-array
191
181
  * @deprecated
192
182
  */
193
183
  'unicorn/no-instanceof-array'?: Linter.RuleEntry<[]>
194
184
  /**
195
185
  * Disallow `instanceof` with built-in objects
196
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-instanceof-builtins.md
186
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-instanceof-builtins.md
197
187
  */
198
188
  'unicorn/no-instanceof-builtins'?: Linter.RuleEntry<UnicornNoInstanceofBuiltins>
199
189
  /**
200
190
  * Disallow invalid options in `fetch()` and `new Request()`.
201
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-invalid-fetch-options.md
191
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-invalid-fetch-options.md
202
192
  */
203
193
  'unicorn/no-invalid-fetch-options'?: Linter.RuleEntry<[]>
204
194
  /**
205
195
  * Prevent calling `EventTarget#removeEventListener()` with the result of an expression.
206
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-invalid-remove-event-listener.md
196
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-invalid-remove-event-listener.md
207
197
  */
208
198
  'unicorn/no-invalid-remove-event-listener'?: Linter.RuleEntry<[]>
209
199
  /**
210
200
  * Disallow identifiers starting with `new` or `class`.
211
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-keyword-prefix.md
201
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-keyword-prefix.md
212
202
  */
213
203
  'unicorn/no-keyword-prefix'?: Linter.RuleEntry<UnicornNoKeywordPrefix>
214
204
  /**
215
205
  * Replaced by `unicorn/no-unnecessary-slice-end` which covers more cases.
216
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/deprecated-rules.md#no-length-as-slice-end
206
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/deprecated-rules.md#no-length-as-slice-end
217
207
  * @deprecated
218
208
  */
219
209
  'unicorn/no-length-as-slice-end'?: Linter.RuleEntry<[]>
220
210
  /**
221
211
  * Disallow `if` statements as the only statement in `if` blocks without `else`.
222
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-lonely-if.md
212
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-lonely-if.md
223
213
  */
224
214
  'unicorn/no-lonely-if'?: Linter.RuleEntry<[]>
225
215
  /**
226
216
  * Disallow a magic number as the `depth` argument in `Array#flat(…).`
227
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-magic-array-flat-depth.md
217
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-magic-array-flat-depth.md
228
218
  */
229
219
  'unicorn/no-magic-array-flat-depth'?: Linter.RuleEntry<[]>
230
220
  /**
231
221
  * Disallow named usage of default import and export.
232
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-named-default.md
222
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-named-default.md
233
223
  */
234
224
  'unicorn/no-named-default'?: Linter.RuleEntry<[]>
235
225
  /**
236
226
  * Disallow negated conditions.
237
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-negated-condition.md
227
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-negated-condition.md
238
228
  */
239
229
  'unicorn/no-negated-condition'?: Linter.RuleEntry<[]>
240
230
  /**
241
231
  * Disallow negated expression in equality check.
242
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-negation-in-equality-check.md
232
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-negation-in-equality-check.md
243
233
  */
244
234
  'unicorn/no-negation-in-equality-check'?: Linter.RuleEntry<[]>
245
235
  /**
246
236
  * Disallow nested ternary expressions.
247
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-nested-ternary.md
237
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-nested-ternary.md
248
238
  */
249
239
  'unicorn/no-nested-ternary'?: Linter.RuleEntry<[]>
250
240
  /**
251
241
  * Disallow `new Array()`.
252
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-new-array.md
242
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-new-array.md
253
243
  */
254
244
  'unicorn/no-new-array'?: Linter.RuleEntry<[]>
255
245
  /**
256
246
  * Enforce the use of `Buffer.from()` and `Buffer.alloc()` instead of the deprecated `new Buffer()`.
257
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-new-buffer.md
247
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-new-buffer.md
258
248
  */
259
249
  'unicorn/no-new-buffer'?: Linter.RuleEntry<[]>
260
250
  /**
261
251
  * Disallow the use of the `null` literal.
262
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-null.md
252
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-null.md
263
253
  */
264
254
  'unicorn/no-null'?: Linter.RuleEntry<UnicornNoNull>
265
255
  /**
266
256
  * Disallow the use of objects as default parameters.
267
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-object-as-default-parameter.md
257
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-object-as-default-parameter.md
268
258
  */
269
259
  'unicorn/no-object-as-default-parameter'?: Linter.RuleEntry<[]>
270
260
  /**
271
261
  * Disallow `process.exit()`.
272
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-process-exit.md
262
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-process-exit.md
273
263
  */
274
264
  'unicorn/no-process-exit'?: Linter.RuleEntry<[]>
275
265
  /**
276
266
  * Disallow passing single-element arrays to `Promise` methods.
277
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-single-promise-in-promise-methods.md
267
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-single-promise-in-promise-methods.md
278
268
  */
279
269
  'unicorn/no-single-promise-in-promise-methods'?: Linter.RuleEntry<[]>
280
270
  /**
281
271
  * Disallow classes that only have static members.
282
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-static-only-class.md
272
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-static-only-class.md
283
273
  */
284
274
  'unicorn/no-static-only-class'?: Linter.RuleEntry<[]>
285
275
  /**
286
276
  * Disallow `then` property.
287
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-thenable.md
277
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-thenable.md
288
278
  */
289
279
  'unicorn/no-thenable'?: Linter.RuleEntry<[]>
290
280
  /**
291
281
  * Disallow assigning `this` to a variable.
292
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-this-assignment.md
282
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-this-assignment.md
293
283
  */
294
284
  'unicorn/no-this-assignment'?: Linter.RuleEntry<[]>
295
285
  /**
296
286
  * Disallow comparing `undefined` using `typeof`.
297
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-typeof-undefined.md
287
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-typeof-undefined.md
298
288
  */
299
289
  'unicorn/no-typeof-undefined'?: Linter.RuleEntry<UnicornNoTypeofUndefined>
300
290
  /**
301
291
  * Disallow using `1` as the `depth` argument of `Array#flat()`.
302
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-array-flat-depth.md
292
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unnecessary-array-flat-depth.md
303
293
  */
304
294
  'unicorn/no-unnecessary-array-flat-depth'?: Linter.RuleEntry<[]>
305
295
  /**
306
296
  * Disallow using `.length` or `Infinity` as the `deleteCount` or `skipCount` argument of `Array#{splice,toSpliced}()`.
307
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-array-splice-count.md
297
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unnecessary-array-splice-count.md
308
298
  */
309
299
  'unicorn/no-unnecessary-array-splice-count'?: Linter.RuleEntry<[]>
310
300
  /**
311
301
  * Disallow awaiting non-promise values.
312
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-await.md
302
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unnecessary-await.md
313
303
  */
314
304
  'unicorn/no-unnecessary-await'?: Linter.RuleEntry<[]>
315
305
  /**
316
306
  * Enforce the use of built-in methods instead of unnecessary polyfills.
317
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-polyfills.md
307
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unnecessary-polyfills.md
318
308
  */
319
309
  'unicorn/no-unnecessary-polyfills'?: Linter.RuleEntry<UnicornNoUnnecessaryPolyfills>
320
310
  /**
321
311
  * Disallow using `.length` or `Infinity` as the `end` argument of `{Array,String,TypedArray}#slice()`.
322
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unnecessary-slice-end.md
312
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unnecessary-slice-end.md
323
313
  */
324
314
  'unicorn/no-unnecessary-slice-end'?: Linter.RuleEntry<[]>
325
315
  /**
326
316
  * Disallow unreadable array destructuring.
327
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unreadable-array-destructuring.md
317
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unreadable-array-destructuring.md
328
318
  */
329
319
  'unicorn/no-unreadable-array-destructuring'?: Linter.RuleEntry<[]>
330
320
  /**
331
321
  * Disallow unreadable IIFEs.
332
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unreadable-iife.md
322
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unreadable-iife.md
333
323
  */
334
324
  'unicorn/no-unreadable-iife'?: Linter.RuleEntry<[]>
335
325
  /**
336
326
  * Disallow unused object properties.
337
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-unused-properties.md
327
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-unused-properties.md
338
328
  */
339
329
  'unicorn/no-unused-properties'?: Linter.RuleEntry<[]>
340
- /**
341
- * Disallow useless values or fallbacks in `Set`, `Map`, `WeakSet`, or `WeakMap`.
342
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-collection-argument.md
343
- */
344
- 'unicorn/no-useless-collection-argument'?: Linter.RuleEntry<[]>
345
330
  /**
346
331
  * Disallow unnecessary `Error.captureStackTrace(…)`.
347
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-error-capture-stack-trace.md
332
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-error-capture-stack-trace.md
348
333
  */
349
334
  'unicorn/no-useless-error-capture-stack-trace'?: Linter.RuleEntry<[]>
350
335
  /**
351
336
  * Disallow useless fallback when spreading in object literals.
352
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-fallback-in-spread.md
337
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-fallback-in-spread.md
353
338
  */
354
339
  'unicorn/no-useless-fallback-in-spread'?: Linter.RuleEntry<[]>
355
340
  /**
356
341
  * Disallow useless array length check.
357
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-length-check.md
342
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-length-check.md
358
343
  */
359
344
  'unicorn/no-useless-length-check'?: Linter.RuleEntry<[]>
360
345
  /**
361
346
  * Disallow returning/yielding `Promise.resolve/reject()` in async functions or promise callbacks
362
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-promise-resolve-reject.md
347
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-promise-resolve-reject.md
363
348
  */
364
349
  'unicorn/no-useless-promise-resolve-reject'?: Linter.RuleEntry<[]>
365
350
  /**
366
351
  * Disallow unnecessary spread.
367
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-spread.md
352
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-spread.md
368
353
  */
369
354
  'unicorn/no-useless-spread'?: Linter.RuleEntry<[]>
370
355
  /**
371
356
  * Disallow useless case in switch statements.
372
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-switch-case.md
357
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-switch-case.md
373
358
  */
374
359
  'unicorn/no-useless-switch-case'?: Linter.RuleEntry<[]>
375
360
  /**
376
361
  * Disallow useless `undefined`.
377
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-useless-undefined.md
362
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-useless-undefined.md
378
363
  */
379
364
  'unicorn/no-useless-undefined'?: Linter.RuleEntry<UnicornNoUselessUndefined>
380
365
  /**
381
366
  * Disallow number literals with zero fractions or dangling dots.
382
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/no-zero-fractions.md
367
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/no-zero-fractions.md
383
368
  */
384
369
  'unicorn/no-zero-fractions'?: Linter.RuleEntry<[]>
385
370
  /**
386
371
  * Enforce proper case for numeric literals.
387
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/number-literal-case.md
372
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/number-literal-case.md
388
373
  */
389
374
  'unicorn/number-literal-case'?: Linter.RuleEntry<UnicornNumberLiteralCase>
390
375
  /**
391
376
  * Enforce the style of numeric separators by correctly grouping digits.
392
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/numeric-separators-style.md
377
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/numeric-separators-style.md
393
378
  */
394
379
  'unicorn/numeric-separators-style'?: Linter.RuleEntry<UnicornNumericSeparatorsStyle>
395
380
  /**
396
381
  * Prefer `.addEventListener()` and `.removeEventListener()` over `on`-functions.
397
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-add-event-listener.md
382
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-add-event-listener.md
398
383
  */
399
384
  'unicorn/prefer-add-event-listener'?: Linter.RuleEntry<UnicornPreferAddEventListener>
400
385
  /**
401
386
  * Prefer `.find(…)` and `.findLast(…)` over the first or last element from `.filter(…)`.
402
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-find.md
387
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-array-find.md
403
388
  */
404
389
  'unicorn/prefer-array-find'?: Linter.RuleEntry<UnicornPreferArrayFind>
405
390
  /**
406
391
  * Prefer `Array#flat()` over legacy techniques to flatten arrays.
407
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-flat.md
392
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-array-flat.md
408
393
  */
409
394
  'unicorn/prefer-array-flat'?: Linter.RuleEntry<UnicornPreferArrayFlat>
410
395
  /**
411
396
  * Prefer `.flatMap(…)` over `.map(…).flat()`.
412
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-flat-map.md
397
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-array-flat-map.md
413
398
  */
414
399
  'unicorn/prefer-array-flat-map'?: Linter.RuleEntry<[]>
415
400
  /**
416
401
  * Prefer `Array#{indexOf,lastIndexOf}()` over `Array#{findIndex,findLastIndex}()` when looking for the index of an item.
417
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-index-of.md
402
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-array-index-of.md
418
403
  */
419
404
  'unicorn/prefer-array-index-of'?: Linter.RuleEntry<[]>
420
405
  /**
421
406
  * Prefer `.some(…)` over `.filter(…).length` check and `.{find,findLast,findIndex,findLastIndex}(…)`.
422
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-array-some.md
407
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-array-some.md
423
408
  */
424
409
  'unicorn/prefer-array-some'?: Linter.RuleEntry<[]>
425
410
  /**
426
411
  * Prefer `.at()` method for index access and `String#charAt()`.
427
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-at.md
412
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-at.md
428
413
  */
429
414
  'unicorn/prefer-at'?: Linter.RuleEntry<UnicornPreferAt>
430
- /**
431
- * Prefer `BigInt` literals over the constructor.
432
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-bigint-literals.md
433
- */
434
- 'unicorn/prefer-bigint-literals'?: Linter.RuleEntry<[]>
435
415
  /**
436
416
  * Prefer `Blob#arrayBuffer()` over `FileReader#readAsArrayBuffer(…)` and `Blob#text()` over `FileReader#readAsText(…)`.
437
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-blob-reading-methods.md
417
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-blob-reading-methods.md
438
418
  */
439
419
  'unicorn/prefer-blob-reading-methods'?: Linter.RuleEntry<[]>
440
420
  /**
441
421
  * Prefer class field declarations over `this` assignments in constructors.
442
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-class-fields.md
422
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-class-fields.md
443
423
  */
444
424
  'unicorn/prefer-class-fields'?: Linter.RuleEntry<[]>
445
- /**
446
- * Prefer using `Element#classList.toggle()` to toggle class names.
447
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-classlist-toggle.md
448
- */
449
- 'unicorn/prefer-classlist-toggle'?: Linter.RuleEntry<[]>
450
425
  /**
451
426
  * Prefer `String#codePointAt(…)` over `String#charCodeAt(…)` and `String.fromCodePoint(…)` over `String.fromCharCode(…)`.
452
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-code-point.md
427
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-code-point.md
453
428
  */
454
429
  'unicorn/prefer-code-point'?: Linter.RuleEntry<[]>
455
430
  /**
456
431
  * Prefer `Date.now()` to get the number of milliseconds since the Unix Epoch.
457
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-date-now.md
432
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-date-now.md
458
433
  */
459
434
  'unicorn/prefer-date-now'?: Linter.RuleEntry<[]>
460
435
  /**
461
436
  * Prefer default parameters over reassignment.
462
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-default-parameters.md
437
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-default-parameters.md
463
438
  */
464
439
  'unicorn/prefer-default-parameters'?: Linter.RuleEntry<[]>
465
440
  /**
466
441
  * Prefer `Node#append()` over `Node#appendChild()`.
467
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-append.md
442
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-dom-node-append.md
468
443
  */
469
444
  'unicorn/prefer-dom-node-append'?: Linter.RuleEntry<[]>
470
445
  /**
471
446
  * Prefer using `.dataset` on DOM elements over calling attribute methods.
472
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-dataset.md
447
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-dom-node-dataset.md
473
448
  */
474
449
  'unicorn/prefer-dom-node-dataset'?: Linter.RuleEntry<[]>
475
450
  /**
476
451
  * Prefer `childNode.remove()` over `parentNode.removeChild(childNode)`.
477
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-remove.md
452
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-dom-node-remove.md
478
453
  */
479
454
  'unicorn/prefer-dom-node-remove'?: Linter.RuleEntry<[]>
480
455
  /**
481
456
  * Prefer `.textContent` over `.innerText`.
482
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-dom-node-text-content.md
457
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-dom-node-text-content.md
483
458
  */
484
459
  'unicorn/prefer-dom-node-text-content'?: Linter.RuleEntry<[]>
485
460
  /**
486
461
  * Prefer `EventTarget` over `EventEmitter`.
487
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-event-target.md
462
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-event-target.md
488
463
  */
489
464
  'unicorn/prefer-event-target'?: Linter.RuleEntry<[]>
490
465
  /**
491
466
  * Prefer `export…from` when re-exporting.
492
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-export-from.md
467
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-export-from.md
493
468
  */
494
469
  'unicorn/prefer-export-from'?: Linter.RuleEntry<UnicornPreferExportFrom>
495
470
  /**
496
471
  * Prefer `globalThis` over `window`, `self`, and `global`.
497
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-global-this.md
472
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-global-this.md
498
473
  */
499
474
  'unicorn/prefer-global-this'?: Linter.RuleEntry<[]>
500
475
  /**
501
476
  * Prefer `import.meta.{dirname,filename}` over legacy techniques for getting file paths.
502
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-import-meta-properties.md
477
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-import-meta-properties.md
503
478
  */
504
479
  'unicorn/prefer-import-meta-properties'?: Linter.RuleEntry<[]>
505
480
  /**
506
481
  * Prefer `.includes()` over `.indexOf()`, `.lastIndexOf()`, and `Array#some()` when checking for existence or non-existence.
507
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-includes.md
482
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-includes.md
508
483
  */
509
484
  'unicorn/prefer-includes'?: Linter.RuleEntry<[]>
510
485
  /**
511
486
  * Prefer reading a JSON file as a buffer.
512
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-json-parse-buffer.md
487
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-json-parse-buffer.md
513
488
  */
514
489
  'unicorn/prefer-json-parse-buffer'?: Linter.RuleEntry<[]>
515
490
  /**
516
491
  * Prefer `KeyboardEvent#key` over `KeyboardEvent#keyCode`.
517
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-keyboard-event-key.md
492
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-keyboard-event-key.md
518
493
  */
519
494
  'unicorn/prefer-keyboard-event-key'?: Linter.RuleEntry<[]>
520
495
  /**
521
496
  * Prefer using a logical operator over a ternary.
522
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-logical-operator-over-ternary.md
497
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-logical-operator-over-ternary.md
523
498
  */
524
499
  'unicorn/prefer-logical-operator-over-ternary'?: Linter.RuleEntry<[]>
525
500
  /**
526
501
  * Prefer `Math.min()` and `Math.max()` over ternaries for simple comparisons.
527
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-math-min-max.md
502
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-math-min-max.md
528
503
  */
529
504
  'unicorn/prefer-math-min-max'?: Linter.RuleEntry<[]>
530
505
  /**
531
506
  * Enforce the use of `Math.trunc` instead of bitwise operators.
532
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-math-trunc.md
507
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-math-trunc.md
533
508
  */
534
509
  'unicorn/prefer-math-trunc'?: Linter.RuleEntry<[]>
535
510
  /**
536
511
  * Prefer `.before()` over `.insertBefore()`, `.replaceWith()` over `.replaceChild()`, prefer one of `.before()`, `.after()`, `.append()` or `.prepend()` over `insertAdjacentText()` and `insertAdjacentElement()`.
537
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-modern-dom-apis.md
512
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-modern-dom-apis.md
538
513
  */
539
514
  'unicorn/prefer-modern-dom-apis'?: Linter.RuleEntry<[]>
540
515
  /**
541
516
  * Prefer modern `Math` APIs over legacy patterns.
542
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-modern-math-apis.md
517
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-modern-math-apis.md
543
518
  */
544
519
  'unicorn/prefer-modern-math-apis'?: Linter.RuleEntry<[]>
545
520
  /**
546
521
  * Prefer JavaScript modules (ESM) over CommonJS.
547
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-module.md
522
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-module.md
548
523
  */
549
524
  'unicorn/prefer-module'?: Linter.RuleEntry<[]>
550
525
  /**
551
526
  * Prefer using `String`, `Number`, `BigInt`, `Boolean`, and `Symbol` directly.
552
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-native-coercion-functions.md
527
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-native-coercion-functions.md
553
528
  */
554
529
  'unicorn/prefer-native-coercion-functions'?: Linter.RuleEntry<[]>
555
530
  /**
556
531
  * Prefer negative index over `.length - index` when possible.
557
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-negative-index.md
532
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-negative-index.md
558
533
  */
559
534
  'unicorn/prefer-negative-index'?: Linter.RuleEntry<[]>
560
535
  /**
561
536
  * Prefer using the `node:` protocol when importing Node.js builtin modules.
562
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-node-protocol.md
537
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-node-protocol.md
563
538
  */
564
539
  'unicorn/prefer-node-protocol'?: Linter.RuleEntry<[]>
565
540
  /**
566
541
  * Prefer `Number` static properties over global ones.
567
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-number-properties.md
542
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-number-properties.md
568
543
  */
569
544
  'unicorn/prefer-number-properties'?: Linter.RuleEntry<UnicornPreferNumberProperties>
570
545
  /**
571
546
  * Prefer using `Object.fromEntries(…)` to transform a list of key-value pairs into an object.
572
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-object-from-entries.md
547
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-object-from-entries.md
573
548
  */
574
549
  'unicorn/prefer-object-from-entries'?: Linter.RuleEntry<UnicornPreferObjectFromEntries>
575
550
  /**
576
551
  * Prefer omitting the `catch` binding parameter.
577
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-optional-catch-binding.md
552
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-optional-catch-binding.md
578
553
  */
579
554
  'unicorn/prefer-optional-catch-binding'?: Linter.RuleEntry<[]>
580
555
  /**
581
556
  * Prefer borrowing methods from the prototype instead of the instance.
582
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-prototype-methods.md
557
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-prototype-methods.md
583
558
  */
584
559
  'unicorn/prefer-prototype-methods'?: Linter.RuleEntry<[]>
585
560
  /**
586
561
  * Prefer `.querySelector()` over `.getElementById()`, `.querySelectorAll()` over `.getElementsByClassName()` and `.getElementsByTagName()` and `.getElementsByName()`.
587
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-query-selector.md
562
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-query-selector.md
588
563
  */
589
564
  'unicorn/prefer-query-selector'?: Linter.RuleEntry<[]>
590
565
  /**
591
566
  * Prefer `Reflect.apply()` over `Function#apply()`.
592
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-reflect-apply.md
567
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-reflect-apply.md
593
568
  */
594
569
  'unicorn/prefer-reflect-apply'?: Linter.RuleEntry<[]>
595
570
  /**
596
571
  * Prefer `RegExp#test()` over `String#match()` and `RegExp#exec()`.
597
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-regexp-test.md
572
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-regexp-test.md
598
573
  */
599
574
  'unicorn/prefer-regexp-test'?: Linter.RuleEntry<[]>
600
- /**
601
- * Prefer `Response.json()` over `new Response(JSON.stringify())`.
602
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-response-static-json.md
603
- */
604
- 'unicorn/prefer-response-static-json'?: Linter.RuleEntry<[]>
605
575
  /**
606
576
  * Prefer `Set#has()` over `Array#includes()` when checking for existence or non-existence.
607
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-set-has.md
577
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-set-has.md
608
578
  */
609
579
  'unicorn/prefer-set-has'?: Linter.RuleEntry<[]>
610
580
  /**
611
581
  * Prefer using `Set#size` instead of `Array#length`.
612
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-set-size.md
582
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-set-size.md
613
583
  */
614
584
  'unicorn/prefer-set-size'?: Linter.RuleEntry<[]>
615
585
  /**
616
586
  * Enforce combining multiple `Array#push()`, `Element#classList.{add,remove}()`, and `importScripts()` into one call.
617
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-single-call.md
587
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-single-call.md
618
588
  */
619
589
  'unicorn/prefer-single-call'?: Linter.RuleEntry<UnicornPreferSingleCall>
620
590
  /**
621
591
  * Prefer the spread operator over `Array.from(…)`, `Array#concat(…)`, `Array#{slice,toSpliced}()` and `String#split('')`.
622
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-spread.md
592
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-spread.md
623
593
  */
624
594
  'unicorn/prefer-spread'?: Linter.RuleEntry<[]>
625
595
  /**
626
596
  * Prefer using the `String.raw` tag to avoid escaping `\`.
627
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-raw.md
597
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-string-raw.md
628
598
  */
629
599
  'unicorn/prefer-string-raw'?: Linter.RuleEntry<[]>
630
600
  /**
631
601
  * Prefer `String#replaceAll()` over regex searches with the global flag.
632
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-replace-all.md
602
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-string-replace-all.md
633
603
  */
634
604
  'unicorn/prefer-string-replace-all'?: Linter.RuleEntry<[]>
635
605
  /**
636
606
  * Prefer `String#slice()` over `String#substr()` and `String#substring()`.
637
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-slice.md
607
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-string-slice.md
638
608
  */
639
609
  'unicorn/prefer-string-slice'?: Linter.RuleEntry<[]>
640
610
  /**
641
611
  * Prefer `String#startsWith()` & `String#endsWith()` over `RegExp#test()`.
642
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-starts-ends-with.md
612
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-string-starts-ends-with.md
643
613
  */
644
614
  'unicorn/prefer-string-starts-ends-with'?: Linter.RuleEntry<[]>
645
615
  /**
646
616
  * Prefer `String#trimStart()` / `String#trimEnd()` over `String#trimLeft()` / `String#trimRight()`.
647
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-string-trim-start-end.md
617
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-string-trim-start-end.md
648
618
  */
649
619
  'unicorn/prefer-string-trim-start-end'?: Linter.RuleEntry<[]>
650
620
  /**
651
621
  * Prefer using `structuredClone` to create a deep clone.
652
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-structured-clone.md
622
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-structured-clone.md
653
623
  */
654
624
  'unicorn/prefer-structured-clone'?: Linter.RuleEntry<UnicornPreferStructuredClone>
655
625
  /**
656
626
  * Prefer `switch` over multiple `else-if`.
657
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-switch.md
627
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-switch.md
658
628
  */
659
629
  'unicorn/prefer-switch'?: Linter.RuleEntry<UnicornPreferSwitch>
660
630
  /**
661
631
  * Prefer ternary expressions over simple `if-else` statements.
662
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-ternary.md
632
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-ternary.md
663
633
  */
664
634
  'unicorn/prefer-ternary'?: Linter.RuleEntry<UnicornPreferTernary>
665
635
  /**
666
636
  * Prefer top-level await over top-level promises and async function calls.
667
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-top-level-await.md
637
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-top-level-await.md
668
638
  */
669
639
  'unicorn/prefer-top-level-await'?: Linter.RuleEntry<[]>
670
640
  /**
671
641
  * Enforce throwing `TypeError` in type checking conditions.
672
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prefer-type-error.md
642
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prefer-type-error.md
673
643
  */
674
644
  'unicorn/prefer-type-error'?: Linter.RuleEntry<[]>
675
645
  /**
676
646
  * Prevent abbreviations.
677
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/prevent-abbreviations.md
647
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/prevent-abbreviations.md
678
648
  */
679
649
  'unicorn/prevent-abbreviations'?: Linter.RuleEntry<UnicornPreventAbbreviations>
680
650
  /**
681
651
  * Enforce consistent relative URL style.
682
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/relative-url-style.md
652
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/relative-url-style.md
683
653
  */
684
654
  'unicorn/relative-url-style'?: Linter.RuleEntry<UnicornRelativeUrlStyle>
685
655
  /**
686
656
  * Enforce using the separator argument with `Array#join()`.
687
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-array-join-separator.md
657
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/require-array-join-separator.md
688
658
  */
689
659
  'unicorn/require-array-join-separator'?: Linter.RuleEntry<[]>
690
- /**
691
- * Require non-empty module attributes for imports and exports
692
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-module-attributes.md
693
- */
694
- 'unicorn/require-module-attributes'?: Linter.RuleEntry<[]>
695
660
  /**
696
661
  * Require non-empty specifier list in import and export statements.
697
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-module-specifiers.md
662
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/require-module-specifiers.md
698
663
  */
699
664
  'unicorn/require-module-specifiers'?: Linter.RuleEntry<[]>
700
665
  /**
701
666
  * Enforce using the digits argument with `Number#toFixed()`.
702
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-number-to-fixed-digits-argument.md
667
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/require-number-to-fixed-digits-argument.md
703
668
  */
704
669
  'unicorn/require-number-to-fixed-digits-argument'?: Linter.RuleEntry<[]>
705
670
  /**
706
671
  * Enforce using the `targetOrigin` argument with `window.postMessage()`.
707
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/require-post-message-target-origin.md
672
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/require-post-message-target-origin.md
708
673
  */
709
674
  'unicorn/require-post-message-target-origin'?: Linter.RuleEntry<[]>
710
675
  /**
711
676
  * Enforce better string content.
712
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/string-content.md
677
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/string-content.md
713
678
  */
714
679
  'unicorn/string-content'?: Linter.RuleEntry<UnicornStringContent>
715
680
  /**
716
681
  * Enforce consistent brace style for `case` clauses.
717
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/switch-case-braces.md
682
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/switch-case-braces.md
718
683
  */
719
684
  'unicorn/switch-case-braces'?: Linter.RuleEntry<UnicornSwitchCaseBraces>
720
685
  /**
721
686
  * Fix whitespace-insensitive template indentation.
722
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/template-indent.md
687
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/template-indent.md
723
688
  */
724
689
  'unicorn/template-indent'?: Linter.RuleEntry<UnicornTemplateIndent>
725
690
  /**
726
691
  * Enforce consistent case for text encoding identifiers.
727
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/text-encoding-identifier-case.md
692
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/text-encoding-identifier-case.md
728
693
  */
729
- 'unicorn/text-encoding-identifier-case'?: Linter.RuleEntry<UnicornTextEncodingIdentifierCase>
694
+ 'unicorn/text-encoding-identifier-case'?: Linter.RuleEntry<[]>
730
695
  /**
731
696
  * Require `new` when creating an error.
732
- * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v62.0.0/docs/rules/throw-new-error.md
697
+ * @see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v60.0.0/docs/rules/throw-new-error.md
733
698
  */
734
699
  'unicorn/throw-new-error'?: Linter.RuleEntry<[]>
735
700
  }
@@ -801,10 +766,6 @@ type UnicornNoArrayReduce = []|[{
801
766
  type UnicornNoArrayReverse = []|[{
802
767
  allowExpressionStatement?: boolean
803
768
  }]
804
- // ----- unicorn/no-array-sort -----
805
- type UnicornNoArraySort = []|[{
806
- allowExpressionStatement?: boolean
807
- }]
808
769
  // ----- unicorn/no-instanceof-builtins -----
809
770
  type UnicornNoInstanceofBuiltins = []|[{
810
771
  useErrorIsError?: boolean
@@ -953,8 +914,4 @@ type UnicornTemplateIndent = []|[{
953
914
  functions?: string[]
954
915
  selectors?: string[]
955
916
  comments?: string[]
956
- }]
957
- // ----- unicorn/text-encoding-identifier-case -----
958
- type UnicornTextEncodingIdentifierCase = []|[{
959
- withDash?: boolean
960
917
  }]