eslint-plugin-react-x 1.15.2 → 1.15.3-next.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/README.md +2 -0
- package/dist/index.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +124 -87
- package/dist/index.mjs +124 -87
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -30,6 +30,7 @@ export default [
|
|
|
30
30
|
rules: {
|
|
31
31
|
// react-x recommended rules
|
|
32
32
|
"react-x/ensure-forward-ref-using-ref": "warn",
|
|
33
|
+
"react-x/jsx-uses-vars": "warn",
|
|
33
34
|
"react-x/no-access-state-in-setstate": "error",
|
|
34
35
|
"react-x/no-array-index-key": "warn",
|
|
35
36
|
"react-x/no-children-count": "warn",
|
|
@@ -74,6 +75,7 @@ export default [
|
|
|
74
75
|
| `avoid-shorthand-boolean` | Prevents using shorthand syntax for boolean attributes. | 🎨 | | |
|
|
75
76
|
| `avoid-shorthand-fragment` | Prevents using shorthand syntax for fragments. | 🎨 | | |
|
|
76
77
|
| `ensure-forward-ref-using-ref` | Requires that components wrapped with `forwardRef` must have a `ref` parameter. | ✔️ | | |
|
|
78
|
+
| `jsx-uses-vars | Prevents variables used in JSX to be marked as unused. | ✔️ | | |
|
|
77
79
|
| `no-access-state-in-setstate` | Prevents accessing `this.state` inside `setState` calls. | ✔️ | | |
|
|
78
80
|
| `no-array-index-key` | Prevents using array `index` as `key`. | 🧐 | | |
|
|
79
81
|
| `no-children-count` | Prevents using `Children.count`. | ⛔ | | |
|
package/dist/index.d.mts
CHANGED
|
@@ -17,6 +17,7 @@ declare const _default: {
|
|
|
17
17
|
"avoid-shorthand-boolean": _typescript_eslint_utils_ts_eslint.RuleModule<"avoidShorthandBoolean", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
18
18
|
"avoid-shorthand-fragment": _typescript_eslint_utils_ts_eslint.RuleModule<"avoidShorthandFragment", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
19
19
|
"ensure-forward-ref-using-ref": _typescript_eslint_utils_ts_eslint.RuleModule<"ensureForwardRefUsingRef", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
20
|
+
"jsx-uses-vars": _typescript_eslint_utils_ts_eslint.RuleModule<"jsxUsesVars", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
20
21
|
"no-access-state-in-setstate": _typescript_eslint_utils_ts_eslint.RuleModule<"noAccessStateInSetstate", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
21
22
|
"no-array-index-key": _typescript_eslint_utils_ts_eslint.RuleModule<"noArrayIndexKey", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
22
23
|
"no-children-count": _typescript_eslint_utils_ts_eslint.RuleModule<"noChildrenCount", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
package/dist/index.d.ts
CHANGED
|
@@ -17,6 +17,7 @@ declare const _default: {
|
|
|
17
17
|
"avoid-shorthand-boolean": _typescript_eslint_utils_ts_eslint.RuleModule<"avoidShorthandBoolean", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
18
18
|
"avoid-shorthand-fragment": _typescript_eslint_utils_ts_eslint.RuleModule<"avoidShorthandFragment", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
19
19
|
"ensure-forward-ref-using-ref": _typescript_eslint_utils_ts_eslint.RuleModule<"ensureForwardRefUsingRef", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
20
|
+
"jsx-uses-vars": _typescript_eslint_utils_ts_eslint.RuleModule<"jsxUsesVars", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
20
21
|
"no-access-state-in-setstate": _typescript_eslint_utils_ts_eslint.RuleModule<"noAccessStateInSetstate", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
21
22
|
"no-array-index-key": _typescript_eslint_utils_ts_eslint.RuleModule<"noArrayIndexKey", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|
|
22
23
|
"no-children-count": _typescript_eslint_utils_ts_eslint.RuleModule<"noChildrenCount", [], unknown, _typescript_eslint_utils_ts_eslint.RuleListener>;
|