Skip to content

Commit 717fe4c

Browse files
authored
feat: add no-unused-props rule to recommended-type-checked preset, closes #1161 (#1178)
1 parent 2dddf88 commit 717fe4c

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

packages/plugins/eslint-plugin-react-x/src/configs/recommended-type-checked.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export const name = "react-x/recommended-type-checked";
77
export const rules = {
88
...recommendedTypeScript.rules,
99
"react-x/no-leaked-conditional-rendering": "warn",
10+
"react-x/no-unused-props": "warn",
1011
// "react-x/prefer-read-only-props": "warn",
1112
} as const satisfies RulePreset;
1213

packages/plugins/eslint-plugin-react-x/src/rules/no-unused-props.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,14 @@ react-x/no-unused-props
1414
@eslint-react/no-unused-props
1515
```
1616

17+
**Features**
18+
19+
`💭` `🧪`
20+
21+
**Presets**
22+
23+
- `recommended-type-checked`
24+
1725
## Description
1826

1927
Warns about unused component prop declarations.

packages/plugins/eslint-plugin/src/configs/recommended-type-checked.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export const name = "@eslint-react/recommended-type-checked";
77
export const rules = {
88
...recommendedTypeScript.rules,
99
"@eslint-react/no-leaked-conditional-rendering": "warn",
10+
"@eslint-react/no-unused-props": "warn",
1011
// "@eslint-react/prefer-read-only-props": "warn",
1112
} as const satisfies RulePreset;
1213

0 commit comments

Comments
 (0)