@allthings/eslint-config 3.3.1 → 3.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +9 -1
- package/node.js +6 -1
- package/package.json +2 -2
package/index.js
CHANGED
|
@@ -271,21 +271,26 @@ export default [
|
|
|
271
271
|
'unicorn/import-style': 'warn',
|
|
272
272
|
'unicorn/no-anonymous-default-export': 'off',
|
|
273
273
|
'unicorn/no-array-reduce': 'off',
|
|
274
|
+
// .reverse() mutates in place — semantic + perf cost to force .toReversed()
|
|
275
|
+
'unicorn/no-array-reverse': 'off',
|
|
276
|
+
// .sort() mutates in place — same story as no-array-reverse
|
|
277
|
+
'unicorn/no-array-sort': 'off',
|
|
274
278
|
'unicorn/no-await-expression-member': 'warn',
|
|
275
279
|
'unicorn/no-console-spaces': 'off',
|
|
276
280
|
'unicorn/no-document-cookie': 'warn',
|
|
277
281
|
'unicorn/no-empty-file': 'off',
|
|
278
282
|
'unicorn/no-hex-escape': 'warn',
|
|
279
283
|
'unicorn/no-invalid-remove-event-listener': 'warn',
|
|
284
|
+
'unicorn/no-named-default': 'warn',
|
|
280
285
|
'unicorn/no-nested-ternary': 'off',
|
|
281
286
|
// because we have a lot of logic depends on null
|
|
282
287
|
'unicorn/no-null': 'warn',
|
|
283
288
|
'unicorn/no-object-as-default-parameter': 'warn',
|
|
284
289
|
'unicorn/no-single-promise-in-promise-methods': 'warn',
|
|
285
290
|
'unicorn/no-unreadable-array-destructuring': 'off',
|
|
286
|
-
'unicorn/no-unsafe-regex': 'off',
|
|
287
291
|
'unicorn/no-unused-properties': 'warn',
|
|
288
292
|
'unicorn/no-zero-fractions': 'off',
|
|
293
|
+
'unicorn/prefer-class-fields': 'warn',
|
|
289
294
|
'unicorn/prefer-export-from': 'off',
|
|
290
295
|
'unicorn/prefer-global-this': 'warn',
|
|
291
296
|
'unicorn/prefer-includes': 'off',
|
|
@@ -298,6 +303,8 @@ export default [
|
|
|
298
303
|
'unicorn/prefer-regexp-test': 'off',
|
|
299
304
|
'unicorn/prefer-set-has': 'off',
|
|
300
305
|
'unicorn/prefer-set-size': 'off',
|
|
306
|
+
// opinionated condition ordering — too noisy
|
|
307
|
+
'unicorn/prefer-simple-condition-first': 'off',
|
|
301
308
|
'unicorn/prefer-string-raw': 'off',
|
|
302
309
|
'unicorn/prefer-string-replace-all': 'off',
|
|
303
310
|
'unicorn/prefer-structured-clone': 'warn',
|
|
@@ -319,6 +326,7 @@ export default [
|
|
|
319
326
|
},
|
|
320
327
|
],
|
|
321
328
|
'unicorn/relative-url-style': 'off',
|
|
329
|
+
'unicorn/require-module-attributes': 'warn',
|
|
322
330
|
'unicorn/switch-case-braces': 'off',
|
|
323
331
|
'unicorn/template-indent': 'off',
|
|
324
332
|
'use-isnan': 'error',
|
package/node.js
CHANGED
|
@@ -236,21 +236,24 @@ export default [
|
|
|
236
236
|
'unicorn/import-style': 'warn',
|
|
237
237
|
'unicorn/no-anonymous-default-export': 'off',
|
|
238
238
|
'unicorn/no-array-reduce': 'off',
|
|
239
|
+
'unicorn/no-array-reverse': 'off',
|
|
240
|
+
'unicorn/no-array-sort': 'off',
|
|
239
241
|
'unicorn/no-await-expression-member': 'warn',
|
|
240
242
|
'unicorn/no-console-spaces': 'off',
|
|
241
243
|
'unicorn/no-document-cookie': 'warn',
|
|
242
244
|
'unicorn/no-empty-file': 'off',
|
|
243
245
|
'unicorn/no-hex-escape': 'warn',
|
|
244
246
|
'unicorn/no-invalid-remove-event-listener': 'warn',
|
|
247
|
+
'unicorn/no-named-default': 'warn',
|
|
245
248
|
'unicorn/no-nested-ternary': 'off',
|
|
246
249
|
// because we have a lot of logic depends on null
|
|
247
250
|
'unicorn/no-null': 'warn',
|
|
248
251
|
'unicorn/no-object-as-default-parameter': 'warn',
|
|
249
252
|
'unicorn/no-single-promise-in-promise-methods': 'warn',
|
|
250
253
|
'unicorn/no-unreadable-array-destructuring': 'off',
|
|
251
|
-
'unicorn/no-unsafe-regex': 'off',
|
|
252
254
|
'unicorn/no-unused-properties': 'warn',
|
|
253
255
|
'unicorn/no-zero-fractions': 'off',
|
|
256
|
+
'unicorn/prefer-class-fields': 'warn',
|
|
254
257
|
'unicorn/prefer-export-from': 'off',
|
|
255
258
|
'unicorn/prefer-global-this': 'warn',
|
|
256
259
|
'unicorn/prefer-includes': 'off',
|
|
@@ -263,6 +266,7 @@ export default [
|
|
|
263
266
|
'unicorn/prefer-regexp-test': 'off',
|
|
264
267
|
'unicorn/prefer-set-has': 'off',
|
|
265
268
|
'unicorn/prefer-set-size': 'off',
|
|
269
|
+
'unicorn/prefer-simple-condition-first': 'off',
|
|
266
270
|
'unicorn/prefer-string-raw': 'off',
|
|
267
271
|
'unicorn/prefer-string-replace-all': 'off',
|
|
268
272
|
'unicorn/prefer-structured-clone': 'warn',
|
|
@@ -284,6 +288,7 @@ export default [
|
|
|
284
288
|
},
|
|
285
289
|
],
|
|
286
290
|
'unicorn/relative-url-style': 'off',
|
|
291
|
+
'unicorn/require-module-attributes': 'warn',
|
|
287
292
|
'unicorn/switch-case-braces': 'off',
|
|
288
293
|
'unicorn/template-indent': 'off',
|
|
289
294
|
'use-isnan': 'error',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@allthings/eslint-config",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "ESlint shareable config for Allthings style",
|
|
6
6
|
"main": "index.js",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"eslint-plugin-react-hooks": "^5.2.0",
|
|
46
46
|
"eslint-plugin-simple-import-sort": "^13.0.0",
|
|
47
47
|
"eslint-plugin-typescript-sort-keys": "^3.3.0",
|
|
48
|
-
"eslint-plugin-unicorn": "^
|
|
48
|
+
"eslint-plugin-unicorn": "^64.0.0",
|
|
49
49
|
"globals": "^17.0.0"
|
|
50
50
|
},
|
|
51
51
|
"peerDependencies": {
|