[Bug]: hook-use-state
is not doing what the documentation says it does
#3872
Labels
hook-use-state
is not doing what the documentation says it does
#3872
Is there an existing issue for this?
Description Overview
hook-use-state
documentation says that the rule checks whether the value and setter variables destructured from a React.useState() call are named symmetrically.It does not say that the rule checks whether the result of a react.useState class is destructured.
Either the description is wrong, or the implementation is wrong.
Expected Behavior
If the rule is actually checking whether the value and setter variables destructured from a React.useState() call are named symmetrically, then the following code sample should be correct.
If it is not, then, the description must be updated to:
eslint-plugin-react version
every
eslint version
v9
node version
v20
The text was updated successfully, but these errors were encountered: