Files
react/packages/eslint-plugin-react-hooks/__tests__
lauren 9336e29d91 [useEvent] Lint for presence of useEvent functions in dependency lists (#25512)
* [useEvent] Lint for presence of useEvent functions in dependency lists

With #25473, the identity of useEvent's return value is no longer stable
across renders. Previously, the ExhaustiveDeps lint rule would only
allow the omission of the useEvent function, but you could still add it
as a dependency.

This PR updates the ExhaustiveDeps rule to explicitly check for the
presence of useEvent functions in dependency lists, and emits a warning
and suggestion/autofixer for removing the dependency.
2022-10-19 12:03:46 -07:00
..