Skip to content

Commit 3941d54

Browse files
committed
Update depreciation info of 'react-x/no-forbidden-props' rule
1 parent 428cd9e commit 3941d54

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

apps/website/content/docs/removed.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ full: true
1414
| `react-x/jsx-no-duplicate-props` | [`react-x/jsx-no-duplicate-props`](/docs/rules/jsx-no-duplicate-props) | 2.0.0 | renamed |
1515
| `react-x/no-comment-textnodes` | [`react-x/jsx-no-comment-textnodes`](/docs/rules/jsx-no-comment-textnodes) | 2.0.0 | renamed |
1616
| `react-x/no-complicated-conditional-rendering` | | 2.0.0 | discontinued |
17-
| `react-x/no-forbidden-props` | | 2.3.1 | deprecated |
17+
| `react-x/no-forbidden-props` | [`no-restricted-syntax`](https://eslint.org/docs/latest/rules/no-restricted-syntax) | 2.3.1 | deprecated |
1818
| `react-x/no-nested-components` | [`react-x/no-nested-component-definitions`](/docs/rules/no-nested-component-definitions) | 2.0.0 | renamed |
1919
| `react-x/prefer-react-namespace-import` | [`react-x/prefer-namespace-import`](/docs/rules/prefer-namespace-import) | 2.0.0 | renamed |
2020
| `react-x/prefer-shorthand-boolean` | [`react-x/jsx-shorthand-boolean`](/docs/rules/jsx-shorthand-boolean) | 2.0.0 | consolidated |

packages/plugins/eslint-plugin-react-x/src/rules/no-forbidden-props.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,16 @@ export default createRule<Options, MessageID>({
3333
meta: {
3434
type: "problem",
3535
defaultOptions: [...defaultOptions],
36-
deprecated: true,
36+
deprecated: {
37+
deprecatedSince: "2.3.1",
38+
message: "This rule is deprecated and will be removed in future versions.",
39+
replacedBy: [{
40+
rule: {
41+
name: "no-restricted-syntax",
42+
url: "https://eslint.org/docs/latest/rules/no-restricted-syntax",
43+
},
44+
}],
45+
},
3746
docs: {
3847
description: "Disallow certain props on components.",
3948
},

0 commit comments

Comments
 (0)