eslint-plugin-wyrm 0.0.9 → 0.0.11

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.
Files changed (149) hide show
  1. package/CHANGELOG.md +48 -0
  2. package/README.md +78 -38
  3. package/dist/_virtual/{rolldown_runtime.mjs → _rolldown/runtime.mjs} +4 -4
  4. package/dist/configs/index.d.mts +2 -1
  5. package/dist/configs/index.mjs +6 -4
  6. package/dist/index.mjs +1 -2
  7. package/dist/rules/de-morgan.d.mts +9 -0
  8. package/dist/rules/de-morgan.mjs +52 -0
  9. package/dist/rules/distribute-boolean-casts.d.mts +3 -1
  10. package/dist/rules/duplicate-destructuring.d.mts +9 -0
  11. package/dist/rules/duplicate-destructuring.mjs +46 -0
  12. package/dist/rules/e.d.mts +11 -0
  13. package/dist/rules/e.mjs +86 -0
  14. package/dist/rules/exact-string-regex.d.mts +9 -0
  15. package/dist/rules/exact-string-regex.mjs +85 -0
  16. package/dist/rules/export-using.d.mts +9 -0
  17. package/dist/rules/export-using.mjs +60 -0
  18. package/dist/rules/generic-constructor-with-hook.d.mts +11 -0
  19. package/dist/rules/generic-constructor-with-hook.mjs +105 -0
  20. package/dist/rules/idiomatic-cast.d.mts +9 -0
  21. package/dist/rules/idiomatic-cast.mjs +53 -0
  22. package/dist/rules/index.d.mts +77 -37
  23. package/dist/rules/index.mjs +83 -3
  24. package/dist/rules/named-export-with-side-effects.d.mts +11 -0
  25. package/dist/rules/named-export-with-side-effects.mjs +74 -0
  26. package/dist/rules/no-commented-out-comment.d.mts +9 -0
  27. package/dist/rules/no-commented-out-comment.mjs +33 -0
  28. package/dist/rules/no-constant-template-expression.d.mts +5 -4
  29. package/dist/rules/no-constant-template-expression.mjs +4 -4
  30. package/dist/rules/no-constructed-error-cause.d.mts +9 -0
  31. package/dist/rules/no-constructed-error-cause.mjs +77 -0
  32. package/dist/rules/no-convoluted-logical-expressions.d.mts +4 -2
  33. package/dist/rules/no-convoluted-logical-expressions.mjs +103 -31
  34. package/dist/rules/no-custom-url-parsing.d.mts +9 -0
  35. package/dist/rules/no-custom-url-parsing.mjs +60 -0
  36. package/dist/rules/no-disallowed-warning-comments.d.mts +9 -0
  37. package/dist/rules/no-disallowed-warning-comments.mjs +86 -0
  38. package/dist/rules/no-duplicated-return.d.mts +4 -2
  39. package/dist/rules/no-duplicated-return.mjs +19 -8
  40. package/dist/rules/no-else-break.d.mts +4 -2
  41. package/dist/rules/no-else-break.mjs +2 -2
  42. package/dist/rules/no-else-continue.d.mts +4 -2
  43. package/dist/rules/no-else-continue.mjs +2 -2
  44. package/dist/rules/no-else-return.d.mts +9 -0
  45. package/dist/rules/no-else-return.mjs +79 -0
  46. package/dist/rules/no-else-throw.d.mts +4 -2
  47. package/dist/rules/no-else-throw.mjs +2 -2
  48. package/dist/rules/no-empty-attribute.d.mts +5 -3
  49. package/dist/rules/no-empty-comment.d.mts +5 -3
  50. package/dist/rules/no-empty-jsx-expression.d.mts +4 -2
  51. package/dist/rules/no-empty-literal-iteration.d.mts +4 -2
  52. package/dist/rules/no-empty-literal-iteration.mjs +1 -1
  53. package/dist/rules/no-extra-false-fallback.d.mts +4 -3
  54. package/dist/rules/no-extra-nested-boolean-cast.d.mts +4 -3
  55. package/dist/rules/no-first-last.d.mts +4 -2
  56. package/dist/rules/no-first-last.mjs +0 -1
  57. package/dist/rules/no-float-length-check.d.mts +9 -0
  58. package/dist/rules/no-float-length-check.mjs +41 -0
  59. package/dist/rules/no-huge-try-block.d.mts +13 -0
  60. package/dist/rules/no-huge-try-block.mjs +71 -0
  61. package/dist/rules/no-huge-useeffect.d.mts +11 -0
  62. package/dist/rules/no-huge-useeffect.mjs +54 -0
  63. package/dist/rules/no-if-length-for.d.mts +9 -0
  64. package/dist/rules/no-if-length-for.mjs +93 -0
  65. package/dist/rules/no-inline-jsdoc-tag.d.mts +5 -3
  66. package/dist/rules/no-invalid-date-literal.d.mts +4 -2
  67. package/dist/rules/no-invalid-date-literal.mjs +41 -16
  68. package/dist/rules/no-jsx-statement.d.mts +4 -2
  69. package/dist/rules/no-lax-array-type.d.mts +9 -0
  70. package/dist/rules/no-lax-array-type.mjs +131 -0
  71. package/dist/rules/no-lax-return-type.d.mts +9 -0
  72. package/dist/rules/no-lax-return-type.mjs +139 -0
  73. package/dist/rules/no-mutable-literal-fill.d.mts +9 -0
  74. package/dist/rules/no-mutable-literal-fill.mjs +66 -0
  75. package/dist/rules/no-numbered-comments.d.mts +9 -0
  76. package/dist/rules/no-numbered-comments.mjs +36 -0
  77. package/dist/rules/no-obvious-any.d.mts +9 -0
  78. package/dist/rules/no-obvious-any.mjs +159 -0
  79. package/dist/rules/no-optional-type-guard-param.d.mts +4 -2
  80. package/dist/rules/no-optional-type-guard-param.mjs +29 -0
  81. package/dist/rules/no-out-of-order-comments.d.mts +9 -0
  82. package/dist/rules/no-out-of-order-comments.mjs +52 -0
  83. package/dist/rules/no-possibly-nullish-equality.d.mts +9 -0
  84. package/dist/rules/no-possibly-nullish-equality.mjs +114 -0
  85. package/dist/rules/no-redundant-function-declaration.d.mts +4 -2
  86. package/dist/rules/no-redundant-function-declaration.mjs +13 -11
  87. package/dist/rules/no-return-to-void.d.mts +3 -1
  88. package/dist/rules/no-return-to-void.mjs +1 -1
  89. package/dist/rules/no-self-object-assign.d.mts +9 -0
  90. package/dist/rules/no-self-object-assign.mjs +56 -0
  91. package/dist/rules/no-sloppy-length-check.d.mts +4 -3
  92. package/dist/rules/no-sloppy-length-check.mjs +13 -13
  93. package/dist/rules/no-suspicious-jsx-semicolon.d.mts +4 -3
  94. package/dist/rules/no-ternary-return.d.mts +5 -4
  95. package/dist/rules/no-unassigned-todo.d.mts +4 -2
  96. package/dist/rules/no-unbound-catch-error.d.mts +9 -0
  97. package/dist/rules/no-unbound-catch-error.mjs +30 -0
  98. package/dist/rules/no-unused-mutually-referential.d.mts +9 -0
  99. package/dist/rules/no-unused-mutually-referential.mjs +220 -0
  100. package/dist/rules/no-unused-param-read.d.mts +4 -2
  101. package/dist/rules/no-useless-computed-key.d.mts +4 -2
  102. package/dist/rules/no-useless-iife.d.mts +4 -2
  103. package/dist/rules/no-useless-logical-fallback.d.mts +3 -2
  104. package/dist/rules/no-useless-logical-fallback.mjs +45 -21
  105. package/dist/rules/no-useless-return-undefined.d.mts +3 -1
  106. package/dist/rules/no-useless-return-undefined.mjs +10 -8
  107. package/dist/rules/no-useless-ts-check.d.mts +9 -0
  108. package/dist/rules/no-useless-ts-check.mjs +36 -0
  109. package/dist/rules/no-useless-use-strict.d.mts +4 -2
  110. package/dist/rules/no-useless-usememo.d.mts +4 -2
  111. package/dist/rules/no-useless-usememo.mjs +8 -4
  112. package/dist/rules/no-whitespace-property.d.mts +4 -2
  113. package/dist/rules/no-whitespace-property.mjs +1 -0
  114. package/dist/rules/nullish-object-spread.d.mts +9 -0
  115. package/dist/rules/nullish-object-spread.mjs +37 -0
  116. package/dist/rules/optional-call-expression.d.mts +9 -0
  117. package/dist/rules/optional-call-expression.mjs +117 -0
  118. package/dist/rules/prefer-catch-method.d.mts +4 -2
  119. package/dist/rules/prefer-catch-method.mjs +7 -9
  120. package/dist/rules/prefer-early-return.d.mts +4 -2
  121. package/dist/rules/prefer-early-return.mjs +85 -29
  122. package/dist/rules/prefer-finally.d.mts +9 -0
  123. package/dist/rules/prefer-finally.mjs +131 -0
  124. package/dist/rules/prefer-getorinsert.d.mts +9 -0
  125. package/dist/rules/prefer-getorinsert.mjs +182 -0
  126. package/dist/rules/prefer-has.d.mts +9 -0
  127. package/dist/rules/prefer-has.mjs +71 -0
  128. package/dist/rules/prefer-object-keys-values.d.mts +9 -0
  129. package/dist/rules/prefer-object-keys-values.mjs +80 -0
  130. package/dist/rules/prefer-repeat.d.mts +4 -2
  131. package/dist/rules/prefer-repeat.mjs +0 -2
  132. package/dist/rules/primitive-valueof.d.mts +9 -0
  133. package/dist/rules/primitive-valueof.mjs +50 -0
  134. package/dist/rules/slim-try.d.mts +9 -0
  135. package/dist/rules/slim-try.mjs +152 -0
  136. package/dist/rules/suspicious-map-length.d.mts +9 -0
  137. package/dist/rules/suspicious-map-length.mjs +47 -0
  138. package/dist/rules/unsafe-asserted-chain.d.mts +3 -2
  139. package/dist/rules/unsafe-asserted-chain.mjs +0 -1
  140. package/dist/rules/unused-object-assign.d.mts +9 -0
  141. package/dist/rules/unused-object-assign.mjs +39 -0
  142. package/dist/rules/useless-intermediary-variable.d.mts +9 -0
  143. package/dist/rules/useless-intermediary-variable.mjs +135 -0
  144. package/dist/rules/useless-required.d.mts +9 -0
  145. package/dist/rules/useless-required.mjs +259 -0
  146. package/dist/utils/createRule.d.mts +4 -0
  147. package/dist/utils/negateExpression.mjs +29 -0
  148. package/dist/utils/option.mjs +5 -1
  149. package/package.json +21 -20
package/CHANGELOG.md CHANGED
@@ -1,5 +1,53 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.0.11](https://github.com/mchevestrier/eslint-plugin-wyrm/compare/eslint-plugin-wyrm-v0.0.10...eslint-plugin-wyrm-v0.0.11) (2026-02-26)
4
+
5
+
6
+ ### Features
7
+
8
+ * add prefer-has ([7ec4ac0](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/7ec4ac098582925ffb5cd5f60d98f6eb49877c51))
9
+ * add rule e ([4138e48](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/4138e482609b39c7137a15f1c547bcb93735635d))
10
+ * add rule exact-string-regex ([cee8e77](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/cee8e77e27de3a5d2e89f1c0cb864b3325fb88a8))
11
+ * add rule export-using ([dcf583d](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/dcf583dd4406967ed4abd47a44b5e1dc22ef0341))
12
+ * add rule generic-constructor-with-hook ([adb3aa7](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/adb3aa7661e2c813ec85f553de3c36ca8cc8430a))
13
+ * add rule named-export-with-side-effects ([e31db0e](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/e31db0ea8f9e356726a68de77e8d0629bf3fb3f5))
14
+ * add rule no-commented-out-comment ([106a564](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/106a564e15d8cc2d0fda318f3da6f1be09346207))
15
+ * add rule no-constructed-error-cause ([634f808](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/634f8085f864497d8fd1fdf26acefed0b051120d))
16
+ * add rule no-huge-useeffect ([afca71b](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/afca71b340229b7f2d9b5cca5ad6f57bfe3a468a))
17
+ * add rule no-if-length-for ([1a40623](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/1a40623a03efd5dba7a076889e022d8c84184059))
18
+ * add rule no-lax-array-type ([095f1f2](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/095f1f26f283083a1037821c35c9f177de3d78e0))
19
+ * add rule no-lax-return-type ([a34ac88](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/a34ac88220d6c18af23aaa8db5b0c49b3cd08fe5))
20
+ * add rule no-unused-mutually-referential ([dec8d1c](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/dec8d1c87e6e5aac8be795e22ee5e310f1569513))
21
+ * add rule no-useless-ts-check ([ae7aed5](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/ae7aed598e2505b2f79d028b504a8cdd4dffbcbf))
22
+ * add rule nullish-object-spread ([377eafd](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/377eafd11ab55522d3de885523c5f844b33b4a88))
23
+ * add rule prefer-finally ([33286b5](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/33286b569ee809a82a921125d1043e204d0e19a6))
24
+ * add rule prefer-getorinsert ([adf46a1](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/adf46a139e6774c2ea189c9318a5bf654db5839f))
25
+ * add rule prefer-object-keys-values ([eb973f6](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/eb973f66d3d1340267b271b0768d8f7cae54d8ef))
26
+ * add rule slim-try ([c3ebfcf](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/c3ebfcf07cb534040baaeb4aaa140b4896592e94))
27
+ * add rule useless-required ([51dd82a](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/51dd82a72c80ca8c83573ae1f6f621da6a24ad50))
28
+
29
+ ## [0.0.10](https://github.com/mchevestrier/eslint-plugin-wyrm/compare/eslint-plugin-wyrm-v0.0.9...eslint-plugin-wyrm-v0.0.10) (2026-01-31)
30
+
31
+
32
+ ### Features
33
+
34
+ * add more rules ([8e6c2f7](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/8e6c2f708f284fc95b6e01f41721df9cac84e88c))
35
+ * add rule idiomatic-cast ([9ad2ac1](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/9ad2ac14413332c6a0b46be7e50d20937e97fe52))
36
+ * add rule no-float-length-check ([0ae7f64](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/0ae7f643766713692bbdf7e0b621c45f2d681444))
37
+ * add rule no-obvious-any ([81b490f](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/81b490f9a3be5532881b1576a12c3a96b482f777))
38
+ * add rule suspicious-map-length ([e014a51](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/e014a517e7e94580f2cb17fefc9731c6c343039a))
39
+ * add rule useless-intermediary-variable ([4689576](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/468957692bb13acdc353a291259978b044f5548f))
40
+ * add rules duplicate-destructuring & primitive-valueof ([cadbb5a](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/cadbb5a165da38239f2e2b66ce1aa55da155d383))
41
+
42
+
43
+ ### Bug Fixes
44
+
45
+ * add more tautologies ([9002744](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/900274405c0b9bc86106a7c7cab58c9a87495e02))
46
+ * add no-disallowed-warning-comments ([c7487e7](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/c7487e7396cb959225a8dba1f90651eaadb9e517))
47
+ * add no-else-return ([f878353](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/f878353e91e8171758cc37c75b40c063706a4f44))
48
+ * negated fallback ([68dc22a](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/68dc22ab962815b02cfa302684c7e490ae8c5f1e))
49
+ * **prefer-early-return:** negate expression ([b12f2e1](https://github.com/mchevestrier/eslint-plugin-wyrm/commit/b12f2e1f4ad991dcfbb2e7625020e09ef4400543))
50
+
3
51
  ## [0.0.9](https://github.com/mchevestrier/eslint-plugin-wyrm/compare/eslint-plugin-wyrm-v0.0.8...eslint-plugin-wyrm-v0.0.9) (2025-11-30)
4
52
 
5
53
 
package/README.md CHANGED
@@ -49,43 +49,83 @@ export default defineConfig([
49
49
  💡 Manually fixable by [editor suggestions](https://eslint.org/docs/latest/use/core-concepts#rule-suggestions).\
50
50
  💭 Requires [type information](https://typescript-eslint.io/linting/typed-linting).
51
51
 
52
- | Name                              | Description | 💼 | 🔧 | 💡 | 💭 |
53
- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | :------------------------------------------------------------------------ | :---------- | :-- | :-- | :-- |
54
- | [distribute-boolean-casts](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/distribute-boolean-casts.md) | Enforce that boolean casts are distributed over logical expressions | 🟪 ☑️ | 🔧 | | |
55
- | [no-constant-template-expression](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-constant-template-expression.md) | Disallow constant string expressions in template literals | ☑️ | | 💡 | 💭 |
56
- | [no-convoluted-logical-expressions](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-convoluted-logical-expressions.md) | Forbid simplifiable logical expressions | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
57
- | [no-duplicated-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-duplicated-return.md) | Forbid duplicated branches with early returns | 🟩 ✅ 🟪 ☑️ | | | |
58
- | [no-else-break](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-break.md) | Forbid unnecessary `else` block after a `break` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
59
- | [no-else-continue](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-continue.md) | Forbid unnecessary `else` block after a `continue` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
60
- | [no-else-throw](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-throw.md) | Forbid unnecessary `else` block after a `throw` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
61
- | [no-empty-attribute](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-attribute.md) | Forbid some empty JSX attributes | 🟪 ☑️ | | | |
62
- | [no-empty-comment](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-comment.md) | Forbid empty comments | 🟪 ☑️ | | | |
63
- | [no-empty-jsx-expression](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-jsx-expression.md) | Forbid empty JSX expression containers | 🟩 ✅ 🟪 ☑️ | | | |
64
- | [no-empty-literal-iteration](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-literal-iteration.md) | Forbid iterating over empty literals | 🟪 ☑️ | | | |
65
- | [no-extra-false-fallback](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-extra-false-fallback.md) | Forbid extra `?? false` in conditions and predicates | 🟪 ☑️ | | 💡 | |
66
- | [no-extra-nested-boolean-cast](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-extra-nested-boolean-cast.md) | Forbid extra boolean casts in conditions and predicates | 🟪 ☑️ | | | |
67
- | [no-first-last](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-first-last.md) | Forbid confusing naming for "first" or "last" | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
68
- | [no-inline-jsdoc-tag](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-inline-jsdoc-tag.md) | Forbid JSDoc tags in code comments | 🟪 ☑️ | | | |
69
- | [no-invalid-date-literal](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-invalid-date-literal.md) | Disallow invalid date literals | 🟩 ✅ 🟪 ☑️ | | | |
70
- | [no-jsx-statement](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-jsx-statement.md) | Forbid JSX expression statements | 🟩 ✅ 🟪 ☑️ | | | |
71
- | [no-optional-type-guard-param](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-optional-type-guard-param.md) | Forbid optional parameters in type guards | 🟩 ✅ 🟪 ☑️ | | | |
72
- | [no-redundant-function-declaration](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-redundant-function-declaration.md) | Forbid redundant function declarations | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
73
- | [no-return-to-void](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-return-to-void.md) | Forbid returning values in void-returning callbacks | ☑️ | | | 💭 |
74
- | [no-sloppy-length-check](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-sloppy-length-check.md) | Forbid sloppy collection size checks | 🟩 ✅ 🟪 ☑️ | | | |
75
- | [no-suspicious-jsx-semicolon](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-suspicious-jsx-semicolon.md) | Forbid suspicious semicolons in JSX | 🟩 ✅ 🟪 ☑️ | | | |
76
- | [no-ternary-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-ternary-return.md) | Disallow ternary conditions in return statements | 🟪 ☑️ | 🔧 | | |
77
- | [no-unassigned-todo](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-unassigned-todo.md) | Forbid unassigned TODO comments | 🟪 ☑️ | | | |
78
- | [no-unused-param-read](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-unused-param-read.md) | Forbid referencing parameters marked as unused with a leading underscore | 🟪 ☑️ | | | |
79
- | [no-useless-computed-key](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-computed-key.md) | Forbid useless computed keys | 🟪 ☑️ | 🔧 | | |
80
- | [no-useless-iife](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-iife.md) | Forbid useless IIFEs | 🟩 ✅ 🟪 ☑️ | | 💡 | |
81
- | [no-useless-logical-fallback](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-logical-fallback.md) | Forbid useless fallback values for logical expressions | ✅ ☑️ | | 💡 | 💭 |
82
- | [no-useless-return-undefined](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-return-undefined.md) | Forbid returning `undefined` in void-returning callbacks | ☑️ | | | 💭 |
83
- | [no-useless-use-strict](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-use-strict.md) | Forbid useless "use strict" directives. | 🟪 ☑️ | | | |
84
- | [no-useless-usememo](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-usememo.md) | Forbid useless `useMemo()` | 🟪 ☑️ | | | |
85
- | [no-whitespace-property](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-whitespace-property.md) | Forbid leading or trailing whitespace in object keys | 🟪 ☑️ | | | |
86
- | [prefer-catch-method](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-catch-method.md) | Enforce usage of `Promise.prototype.catch()` when it improves readability | 🟩 ✅ 🟪 ☑️ | | 💡 | |
87
- | [prefer-early-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-early-return.md) | Require early returns when possible | 🟪 ☑️ | 🔧 | | |
88
- | [prefer-repeat](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-repeat.md) | Enforce usage of `String.prototype.repeat` | 🟩 🟪 ☑️ | | 💡 | |
89
- | [unsafe-asserted-chain](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/unsafe-asserted-chain.md) | Disallow unsafe type assertions on optional chained expressions | ☑️ | | | 💭 |
52
+ | Name                              | Description | 💼 | 🔧 | 💡 | 💭 |
53
+ | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | :----------------------------------------------------------------------------------------------- | :---------- | :-- | :-- | :-- |
54
+ | [de-morgan](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/de-morgan.md) | Enforce using De Morgan's law to simplify negated logical expressions | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
55
+ | [distribute-boolean-casts](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/distribute-boolean-casts.md) | Enforce that boolean casts are distributed over logical expressions | 🟪 ☑️ | 🔧 | | |
56
+ | [duplicate-destructuring](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/duplicate-destructuring.md) | Forbid duplicate keys in object destructuring patterns | 🟩 ✅ 🟪 ☑️ | | | |
57
+ | [e](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/e.md) | Forbid using `e` as a parameter name | 🟪 ☑️ | | 💡 | |
58
+ | [exact-string-regex](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/exact-string-regex.md) | Forbid using a RegEx when string equality would suffice | 🟩 ✅ 🟪 ☑️ | | 💡 | |
59
+ | [export-using](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/export-using.md) | Forbid exporting variables declared with `using` or `await using` | 🟩 ✅ 🟪 ☑️ | | | |
60
+ | [generic-constructor-with-hook](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/generic-constructor-with-hook.md) | Forbid specifying the type arguments on the hook instead of on the generic class | 🟪 ☑️ | 🔧 | | |
61
+ | [idiomatic-cast](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/idiomatic-cast.md) | Enforce idiomatic ways to cast values | ☑️ | 🔧 | | 💭 |
62
+ | [named-export-with-side-effects](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/named-export-with-side-effects.md) | Forbid named exports in files with side effects | 🟩 ✅ 🟪 ☑️ | | | |
63
+ | [no-commented-out-comment](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-commented-out-comment.md) | Forbid commented out comments | 🟩 ✅ 🟪 ☑️ | | | |
64
+ | [no-constant-template-expression](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-constant-template-expression.md) | Disallow constant string expressions in template literals | ☑️ | | 💡 | 💭 |
65
+ | [no-constructed-error-cause](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-constructed-error-cause.md) | Forbid using `Error.cause` with constructed objects | 🟪 ☑️ | | | |
66
+ | [no-convoluted-logical-expressions](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-convoluted-logical-expressions.md) | Forbid simplifiable logical expressions | 🟩 🟪 ☑️ | 🔧 | | |
67
+ | [no-custom-url-parsing](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-custom-url-parsing.md) | Forbid parsing or building URLs by hand | 🟪 ☑️ | | | |
68
+ | [no-disallowed-warning-comments](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-disallowed-warning-comments.md) | Forbid disallowed comments like FIXME, XXX, HACK | 🟪 ☑️ | | | |
69
+ | [no-duplicated-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-duplicated-return.md) | Forbid duplicated branches with early returns | 🟩 ✅ 🟪 ☑️ | | | |
70
+ | [no-else-break](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-break.md) | Forbid unnecessary `else` block after a `break` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
71
+ | [no-else-continue](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-continue.md) | Forbid unnecessary `else` block after a `continue` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
72
+ | [no-else-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-return.md) | Forbid unnecessary `else` block after a `return` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
73
+ | [no-else-throw](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-else-throw.md) | Forbid unnecessary `else` block after a `throw` statement | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
74
+ | [no-empty-attribute](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-attribute.md) | Forbid some empty JSX attributes | 🟪 ☑️ | | | |
75
+ | [no-empty-comment](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-comment.md) | Forbid empty comments | 🟪 ☑️ | | | |
76
+ | [no-empty-jsx-expression](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-jsx-expression.md) | Forbid empty JSX expression containers | 🟩 ✅ 🟪 ☑️ | | | |
77
+ | [no-empty-literal-iteration](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-empty-literal-iteration.md) | Forbid iterating over empty literals | 🟩 ✅ 🟪 ☑️ | | | |
78
+ | [no-extra-false-fallback](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-extra-false-fallback.md) | Forbid extra `?? false` in conditions and predicates | 🟪 ☑️ | | 💡 | |
79
+ | [no-extra-nested-boolean-cast](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-extra-nested-boolean-cast.md) | Forbid extra boolean casts in conditions and predicates | 🟪 ☑️ | | | |
80
+ | [no-first-last](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-first-last.md) | Forbid confusing naming for "first" or "last" | 🟩 ✅ 🟪 ☑️ | | | |
81
+ | [no-float-length-check](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-float-length-check.md) | Forbid comparing a length to a floating point number | 🟩 🟪 ☑️ | | | |
82
+ | [no-huge-try-block](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-huge-try-block.md) | Forbid huge try/catch blocks | 🟪 ☑️ | | | |
83
+ | [no-huge-useeffect](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-huge-useeffect.md) | Forbid huge `useEffect` functions | 🟪 ☑️ | | | |
84
+ | [no-if-length-for](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-if-length-for.md) | Forbid redundant condition for positive length before a loop | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
85
+ | [no-inline-jsdoc-tag](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-inline-jsdoc-tag.md) | Forbid JSDoc tags in code comments | 🟪 ☑️ | | | |
86
+ | [no-invalid-date-literal](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-invalid-date-literal.md) | Disallow invalid date literals | 🟩 ✅ 🟪 ☑️ | | | |
87
+ | [no-jsx-statement](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-jsx-statement.md) | Forbid JSX expression statements | 🟩 ✅ 🟪 ☑️ | | | |
88
+ | [no-lax-array-type](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-lax-array-type.md) | Forbid declaring array types that are wider than the types of the actual elements | ☑️ | | 💡 | 💭 |
89
+ | [no-lax-return-type](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-lax-return-type.md) | Forbid declaring function return types that are wider than the types of the actual return values | ☑️ | | 💡 | 💭 |
90
+ | [no-mutable-literal-fill](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-mutable-literal-fill.md) | Forbid using mutable literals to fill arrays | 🟩 ✅ 🟪 ☑️ | | | |
91
+ | [no-numbered-comments](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-numbered-comments.md) | Forbid numbered comments | | | | |
92
+ | [no-obvious-any](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-obvious-any.md) | Forbid using `any` when a stricter type can be trivially inferred | ☑️ | 🔧 | | 💭 |
93
+ | [no-optional-type-guard-param](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-optional-type-guard-param.md) | Forbid optional parameters in type guards | 🟩 ✅ 🟪 ☑️ | | | |
94
+ | [no-out-of-order-comments](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-out-of-order-comments.md) | Forbid out of order numbered comments | 🟩 ✅ 🟪 ☑️ | | | |
95
+ | [no-possibly-nullish-equality](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-possibly-nullish-equality.md) | Forbid checking the equality of possibly nullish values | ☑️ | | | 💭 |
96
+ | [no-redundant-function-declaration](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-redundant-function-declaration.md) | Forbid redundant function declarations | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
97
+ | [no-return-to-void](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-return-to-void.md) | Forbid returning values in void-returning callbacks | ☑️ | | | 💭 |
98
+ | [no-self-object-assign](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-self-object-assign.md) | Forbid using `Object.assign()` with the same object as both target and source | 🟩 ✅ 🟪 ☑️ | | | |
99
+ | [no-sloppy-length-check](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-sloppy-length-check.md) | Forbid sloppy collection size checks | 🟩 ✅ 🟪 ☑️ | | | |
100
+ | [no-suspicious-jsx-semicolon](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-suspicious-jsx-semicolon.md) | Forbid suspicious semicolons in JSX | 🟩 ✅ 🟪 ☑️ | | | |
101
+ | [no-ternary-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-ternary-return.md) | Disallow ternary conditions in return statements | 🟪 ☑️ | 🔧 | | |
102
+ | [no-unassigned-todo](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-unassigned-todo.md) | Forbid unassigned TODO comments | 🟪 ☑️ | | | |
103
+ | [no-unbound-catch-error](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-unbound-catch-error.md) | Forbid `catch` clauses with unbound errors | 🟪 ☑️ | | | |
104
+ | [no-unused-mutually-referential](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-unused-mutually-referential.md) | Forbid unused functions, even if mutually referential | 🟪 ☑️ | | | |
105
+ | [no-unused-param-read](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-unused-param-read.md) | Forbid referencing parameters marked as unused with a leading underscore | 🟪 ☑️ | | | |
106
+ | [no-useless-computed-key](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-computed-key.md) | Forbid useless computed keys | 🟪 ☑️ | 🔧 | | |
107
+ | [no-useless-iife](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-iife.md) | Forbid useless IIFEs | 🟩 ✅ 🟪 ☑️ | | 💡 | |
108
+ | [no-useless-logical-fallback](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-logical-fallback.md) | Forbid useless fallback values for logical expressions | ✅ ☑️ | | 💡 | 💭 |
109
+ | [no-useless-return-undefined](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-return-undefined.md) | Forbid returning `undefined` in void-returning callbacks | ☑️ | | | 💭 |
110
+ | [no-useless-ts-check](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-ts-check.md) | Forbid useless `@ts-check` comments in TypeScript files | 🟩 ✅ 🟪 ☑️ | | | |
111
+ | [no-useless-use-strict](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-use-strict.md) | Forbid useless "use strict" directives. | 🟪 ☑️ | | | |
112
+ | [no-useless-usememo](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-useless-usememo.md) | Forbid useless `useMemo()` | 🟪 ☑️ | | | |
113
+ | [no-whitespace-property](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/no-whitespace-property.md) | Forbid leading or trailing whitespace in object keys | 🟪 ☑️ | | | |
114
+ | [nullish-object-spread](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/nullish-object-spread.md) | Forbid useless empty object fallback for nullish values in object spread | 🟪 ☑️ | | | |
115
+ | [optional-call-expression](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/optional-call-expression.md) | Enforce using optional call expression syntax | 🟩 ✅ 🟪 ☑️ | 🔧 | | |
116
+ | [prefer-catch-method](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-catch-method.md) | Enforce usage of `Promise.prototype.catch()` when it improves readability | 🟩 ✅ 🟪 ☑️ | | 💡 | |
117
+ | [prefer-early-return](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-early-return.md) | Require early returns when possible | 🟪 ☑️ | 🔧 | | |
118
+ | [prefer-finally](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-finally.md) | Enforce using `finally` rather than duplicating code in `try` and `catch` blocks | 🟪 ☑️ | | 💡 | |
119
+ | [prefer-getorinsert](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-getorinsert.md) | Enforce using `Map#getOrInsert` | 🟪 ☑️ | | 💡 | |
120
+ | [prefer-has](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-has.md) | Enforce using `Map#has` and `Set#has` | 🟪 ☑️ | 🔧 | | |
121
+ | [prefer-object-keys-values](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-object-keys-values.md) | Enforce using `Object.keys()` and `Object.values()` rather than `Object.entries()` | 🟪 ☑️ | | 💡 | |
122
+ | [prefer-repeat](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/prefer-repeat.md) | Enforce usage of `String.prototype.repeat` | 🟩 ✅ 🟪 ☑️ | | 💡 | |
123
+ | [primitive-valueof](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/primitive-valueof.md) | Forbid calling `.valueOf()` on a primitive | ✅ ☑️ | 🔧 | | 💭 |
124
+ | [slim-try](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/slim-try.md) | Enforce moving safe statements out of `try` blocks | 🟪 ☑️ | 🔧 | | |
125
+ | [suspicious-map-length](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/suspicious-map-length.md) | Disallow suspicious use of `.map().length` | 🟩 ✅ 🟪 ☑️ | | 💡 | |
126
+ | [unsafe-asserted-chain](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/unsafe-asserted-chain.md) | Disallow unsafe type assertions on optional chained expressions | ☑️ | | | 💭 |
127
+ | [unused-object-assign](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/unused-object-assign.md) | Disallow unused `Object.assign()` expressions | 🟩 ✅ 🟪 ☑️ | | | |
128
+ | [useless-intermediary-variable](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/useless-intermediary-variable.md) | Disallow unnecessary intermediary variables | 🟪 ☑️ | | 💡 | |
129
+ | [useless-required](https://github.com/mchevestrier/eslint-plugin-wyrm/blob/master/packages/eslint-plugin-wyrm/docs/rules/useless-required.md) | Forbid unnecessary use of `Required<T>` and `Partial<T>` | ☑️ | | 💡 | 💭 |
90
130
 
91
131
  <!-- end auto-generated rules list -->
@@ -1,8 +1,8 @@
1
1
  import { createRequire } from "node:module";
2
2
 
3
- //#region rolldown:runtime
3
+ //#region \0rolldown/runtime.js
4
4
  var __defProp = Object.defineProperty;
5
- var __export = (all, symbols) => {
5
+ var __exportAll = (all, no_symbols) => {
6
6
  let target = {};
7
7
  for (var name in all) {
8
8
  __defProp(target, name, {
@@ -10,11 +10,11 @@ var __export = (all, symbols) => {
10
10
  enumerable: true
11
11
  });
12
12
  }
13
- if (symbols) {
13
+ if (!no_symbols) {
14
14
  __defProp(target, Symbol.toStringTag, { value: "Module" });
15
15
  }
16
16
  return target;
17
17
  };
18
18
 
19
19
  //#endregion
20
- export { __export };
20
+ export { __exportAll };
@@ -2,7 +2,7 @@ import { FlatConfig } from "@typescript-eslint/utils/ts-eslint";
2
2
 
3
3
  //#region lib/configs/index.d.ts
4
4
  declare namespace index_d_exports {
5
- export { all, recommended, recommendedTypeChecked, recommendedTypeCheckedOnly, strict, strictOnly, strictTypeChecked, strictTypeCheckedOnly };
5
+ export { all, disableTypeChecked, recommended, recommendedTypeChecked, recommendedTypeCheckedOnly, strict, strictOnly, strictTypeChecked, strictTypeCheckedOnly };
6
6
  }
7
7
  type Config = FlatConfig.Config;
8
8
  declare const all: Config;
@@ -13,5 +13,6 @@ declare const recommendedTypeCheckedOnly: Config;
13
13
  declare const recommendedTypeChecked: Config;
14
14
  declare const strictTypeCheckedOnly: Config;
15
15
  declare const strictTypeChecked: Config;
16
+ declare const disableTypeChecked: Config;
16
17
  //#endregion
17
18
  export { index_d_exports };
@@ -1,10 +1,11 @@
1
- import { __export } from "../_virtual/rolldown_runtime.mjs";
1
+ import { __exportAll } from "../_virtual/_rolldown/runtime.mjs";
2
2
  import { rules_exports } from "../rules/index.mjs";
3
3
  import { plugin } from "../plugin.mjs";
4
4
 
5
5
  //#region lib/configs/index.ts
6
- var configs_exports = /* @__PURE__ */ __export({
6
+ var configs_exports = /* @__PURE__ */ __exportAll({
7
7
  all: () => all,
8
+ disableTypeChecked: () => disableTypeChecked,
8
9
  recommended: () => recommended,
9
10
  recommendedTypeChecked: () => recommendedTypeChecked,
10
11
  recommendedTypeCheckedOnly: () => recommendedTypeCheckedOnly,
@@ -16,8 +17,8 @@ var configs_exports = /* @__PURE__ */ __export({
16
17
  const baseConfig = { plugins: { get wyrm() {
17
18
  return plugin;
18
19
  } } };
19
- function createConfigWithRules(initialRules, configName, pred) {
20
- const filteredRules = Object.entries(initialRules).filter(([, rule]) => pred(rule)).map(([ruleName]) => [`wyrm/${ruleName}`, "error"]);
20
+ function createConfigWithRules(initialRules, configName, pred, ruleValue = "error") {
21
+ const filteredRules = Object.entries(initialRules).filter(([, rule]) => pred(rule)).map(([ruleName]) => [`wyrm/${ruleName}`, ruleValue]);
21
22
  const rules = Object.fromEntries(filteredRules);
22
23
  return {
23
24
  ...baseConfig,
@@ -71,6 +72,7 @@ const strictTypeChecked = {
71
72
  ...strictTypeCheckedOnly.rules
72
73
  }
73
74
  };
75
+ const disableTypeChecked = createConfigWithRules(rules_exports, "disableTypeChecked", (rule) => !!rule.meta.docs?.requiresTypeChecking, "off");
74
76
 
75
77
  //#endregion
76
78
  export { configs_exports };
package/dist/index.mjs CHANGED
@@ -6,7 +6,6 @@ const plugin = {
6
6
  rules: rules_exports,
7
7
  configs: configs_exports
8
8
  };
9
- var lib_default = plugin;
10
9
 
11
10
  //#endregion
12
- export { lib_default as default };
11
+ export { plugin as default };
@@ -0,0 +1,9 @@
1
+ import { WyrmPluginDocs } from "../utils/createRule.mjs";
2
+ import * as _typescript_eslint_utils_ts_eslint0 from "@typescript-eslint/utils/ts-eslint";
3
+
4
+ //#region lib/rules/de-morgan.d.ts
5
+ declare const _default: _typescript_eslint_utils_ts_eslint0.RuleModule<"deMorgan", [], WyrmPluginDocs, _typescript_eslint_utils_ts_eslint0.RuleListener> & {
6
+ name: string;
7
+ };
8
+ //#endregion
9
+ export { _default };
@@ -0,0 +1,52 @@
1
+ import { createRule } from "../utils/createRule.mjs";
2
+ import { isNegatableOperator, negateExpression } from "../utils/negateExpression.mjs";
3
+ import path from "node:path";
4
+ import { AST_NODE_TYPES } from "@typescript-eslint/utils";
5
+
6
+ //#region lib/rules/de-morgan.ts
7
+ const { name } = path.parse(import.meta.filename);
8
+ var de_morgan_default = createRule({
9
+ name,
10
+ meta: {
11
+ type: "suggestion",
12
+ docs: {
13
+ description: "Enforce using De Morgan's law to simplify negated logical expressions",
14
+ recommended: true
15
+ },
16
+ fixable: "code",
17
+ schema: [],
18
+ messages: { deMorgan: "Use De Morgan's law to simplify this negated logical expression" }
19
+ },
20
+ defaultOptions: [],
21
+ create(context) {
22
+ return { UnaryExpression(node) {
23
+ if (node.operator !== "!") return;
24
+ if (node.parent.type === AST_NODE_TYPES.UnaryExpression && node.parent.operator === "!") return;
25
+ if (node.argument.type === AST_NODE_TYPES.BinaryExpression) {
26
+ if (!isNegatableOperator(node.argument.operator)) return;
27
+ const expr = node.argument;
28
+ context.report({
29
+ node,
30
+ messageId: "deMorgan",
31
+ fix(fixer) {
32
+ return fixer.replaceText(node, `(${negateExpression(expr, context)})`);
33
+ }
34
+ });
35
+ }
36
+ if (node.argument.type === AST_NODE_TYPES.LogicalExpression) {
37
+ if (node.argument.operator === "??") return;
38
+ const expr = node.argument;
39
+ context.report({
40
+ node,
41
+ messageId: "deMorgan",
42
+ fix(fixer) {
43
+ return fixer.replaceText(node, `(${negateExpression(expr, context)})`);
44
+ }
45
+ });
46
+ }
47
+ } };
48
+ }
49
+ });
50
+
51
+ //#endregion
52
+ export { de_morgan_default as default };
@@ -2,6 +2,8 @@ import { WyrmPluginDocs } from "../utils/createRule.mjs";
2
2
  import * as _typescript_eslint_utils_ts_eslint0 from "@typescript-eslint/utils/ts-eslint";
3
3
 
4
4
  //#region lib/rules/distribute-boolean-casts.d.ts
5
- declare const _default: _typescript_eslint_utils_ts_eslint0.RuleModule<"distributeBooleanCast", [], WyrmPluginDocs, _typescript_eslint_utils_ts_eslint0.RuleListener>;
5
+ declare const _default: _typescript_eslint_utils_ts_eslint0.RuleModule<"distributeBooleanCast", [], WyrmPluginDocs, _typescript_eslint_utils_ts_eslint0.RuleListener> & {
6
+ name: string;
7
+ };
6
8
  //#endregion
7
9
  export { _default };
@@ -0,0 +1,9 @@
1
+ import { WyrmPluginDocs } from "../utils/createRule.mjs";
2
+ import * as _typescript_eslint_utils_ts_eslint0 from "@typescript-eslint/utils/ts-eslint";
3
+
4
+ //#region lib/rules/duplicate-destructuring.d.ts
5
+ declare const _default: _typescript_eslint_utils_ts_eslint0.RuleModule<"duplicateKey", [], WyrmPluginDocs, _typescript_eslint_utils_ts_eslint0.RuleListener> & {
6
+ name: string;
7
+ };
8
+ //#endregion
9
+ export { _default };
@@ -0,0 +1,46 @@
1
+ import { createRule } from "../utils/createRule.mjs";
2
+ import path from "node:path";
3
+ import { AST_NODE_TYPES } from "@typescript-eslint/utils";
4
+
5
+ //#region lib/rules/duplicate-destructuring.ts
6
+ const { name } = path.parse(import.meta.filename);
7
+ var duplicate_destructuring_default = createRule({
8
+ name,
9
+ meta: {
10
+ type: "problem",
11
+ docs: {
12
+ description: "Forbid duplicate keys in object destructuring patterns",
13
+ recommended: true
14
+ },
15
+ schema: [],
16
+ messages: { duplicateKey: "This property key appears several times in the destructuring pattern. Make sure this is expected." }
17
+ },
18
+ defaultOptions: [],
19
+ create(context) {
20
+ return { ObjectPattern(node) {
21
+ const seen = /* @__PURE__ */ new Map();
22
+ for (const prop of node.properties) {
23
+ if (prop.type === AST_NODE_TYPES.RestElement) continue;
24
+ const value = extractKeyValue(prop.key);
25
+ if (value === void 0) continue;
26
+ if (!seen.has(value)) {
27
+ seen.set(value, prop.key);
28
+ continue;
29
+ }
30
+ context.report({
31
+ node: prop.key,
32
+ messageId: "duplicateKey"
33
+ });
34
+ }
35
+ } };
36
+ }
37
+ });
38
+ function extractKeyValue(key) {
39
+ if (key.type === AST_NODE_TYPES.Identifier) return key.name;
40
+ if (key.type !== AST_NODE_TYPES.Literal) return;
41
+ if (key.value === null) return "null";
42
+ return key.value.toString();
43
+ }
44
+
45
+ //#endregion
46
+ export { duplicate_destructuring_default as default };
@@ -0,0 +1,11 @@
1
+ import { WyrmPluginDocs } from "../utils/createRule.mjs";
2
+ import * as _typescript_eslint_utils_ts_eslint0 from "@typescript-eslint/utils/ts-eslint";
3
+
4
+ //#region lib/rules/e.d.ts
5
+ declare const _default: _typescript_eslint_utils_ts_eslint0.RuleModule<"noE" | "useOther", [{
6
+ alternatives: string[];
7
+ }], WyrmPluginDocs, _typescript_eslint_utils_ts_eslint0.RuleListener> & {
8
+ name: string;
9
+ };
10
+ //#endregion
11
+ export { _default };
@@ -0,0 +1,86 @@
1
+ import { createRule } from "../utils/createRule.mjs";
2
+ import path from "node:path";
3
+ import { ASTUtils, AST_NODE_TYPES } from "@typescript-eslint/utils";
4
+
5
+ //#region lib/rules/e.ts
6
+ /**
7
+ * @fileoverview
8
+ *
9
+ * In JS, the parameter name `e` is semantically overloaded: it is often used for errors, events, elements...
10
+ * This rule forbids using `e` as a parameter name, in favor of more explicit identifiers like `err`, `evt` or `elt`.
11
+ */
12
+ const { name } = path.parse(import.meta.filename);
13
+ const DEFAULT_ALTERNATIVES = [
14
+ "err",
15
+ "evt",
16
+ "elt"
17
+ ];
18
+ var e_default = createRule({
19
+ name,
20
+ meta: {
21
+ type: "suggestion",
22
+ docs: {
23
+ description: "Forbid using `e` as a parameter name",
24
+ strict: true
25
+ },
26
+ hasSuggestions: true,
27
+ schema: [{
28
+ type: "object",
29
+ properties: { alternatives: {
30
+ description: `Suggested alternatives for identifier names. Default: \`${JSON.stringify(DEFAULT_ALTERNATIVES)}\``,
31
+ type: "array",
32
+ items: { type: "string" }
33
+ } }
34
+ }],
35
+ messages: {
36
+ noE: "Do not use `e` as a parameter name. Use a less ambiguous name.",
37
+ useOther: "Use `{{ ident }}` instead"
38
+ }
39
+ },
40
+ defaultOptions: [{ alternatives: DEFAULT_ALTERNATIVES }],
41
+ create(context, [options]) {
42
+ return {
43
+ ArrowFunctionExpression: checkFunction,
44
+ FunctionExpression: checkFunction,
45
+ FunctionDeclaration: checkFunction,
46
+ CatchClause(node) {
47
+ if (node.param?.type !== AST_NODE_TYPES.Identifier) return;
48
+ checkParam(node.param);
49
+ }
50
+ };
51
+ function checkFunction(node) {
52
+ for (const param of node.params) {
53
+ if (param.type !== AST_NODE_TYPES.Identifier) return;
54
+ checkParam(param);
55
+ }
56
+ }
57
+ function checkParam(param) {
58
+ if (param.name !== "e") return;
59
+ const scope = context.sourceCode.getScope(param);
60
+ const variable = ASTUtils.findVariable(scope, param);
61
+ /* v8 ignore if -- @preserve */
62
+ if (!variable) return;
63
+ const { alternatives } = options;
64
+ context.report({
65
+ node: param,
66
+ messageId: "noE",
67
+ suggest: alternatives.map((alternative) => ({
68
+ messageId: "useOther",
69
+ data: { ident: alternative },
70
+ *fix(fixer) {
71
+ for (const ref of variable.references) yield fixer.replaceText(ref.identifier, alternative);
72
+ if (param.typeAnnotation) {
73
+ const rng = [param.range[0], param.typeAnnotation.range[0]];
74
+ yield fixer.replaceTextRange(rng, alternative);
75
+ return;
76
+ }
77
+ yield fixer.replaceText(param, alternative);
78
+ }
79
+ }))
80
+ });
81
+ }
82
+ }
83
+ });
84
+
85
+ //#endregion
86
+ export { e_default as default };
@@ -0,0 +1,9 @@
1
+ import { WyrmPluginDocs } from "../utils/createRule.mjs";
2
+ import * as _typescript_eslint_utils_ts_eslint0 from "@typescript-eslint/utils/ts-eslint";
3
+
4
+ //#region lib/rules/exact-string-regex.d.ts
5
+ declare const _default: _typescript_eslint_utils_ts_eslint0.RuleModule<"preferEquality", [], WyrmPluginDocs, _typescript_eslint_utils_ts_eslint0.RuleListener> & {
6
+ name: string;
7
+ };
8
+ //#endregion
9
+ export { _default };