Skip to content

Commit faf5744

Browse files
authored
Update hook-use-state.md
Fix an undefined variable.
1 parent 422ff33 commit faf5744

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/rules/hook-use-state.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export default function useColor() {
2727
// useState call is destructured into value + setter pair, but identifier
2828
// names do not follow the [thing, setThing] naming convention
2929
const [color, updateColor] = React.useState();
30-
return useStateResult;
30+
return [color, updateColor];
3131
}
3232
```
3333

0 commit comments

Comments
 (0)