Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update RulesOfHooks with useEvent rules #25285

Merged
merged 6 commits into from
Sep 23, 2022
Merged

Commits on Sep 22, 2022

  1. [ESLint] Treat useEvent retval as stable

    gaearon authored and poteto committed Sep 22, 2022
    Configuration menu
    Copy the full SHA
    ec0e8e8 View commit details
    Browse the repository at this point in the history

Commits on Sep 23, 2022

  1. Check that useEvent is locally called

    This update to the lint rule checks that functions created with
    `useEvent` can only be invoked in a `useEffect`callback or closure.
    They can't be passed down directly as a reference to child components.
    poteto committed Sep 23, 2022
    Configuration menu
    Copy the full SHA
    9804d1a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    16e669b View commit details
    Browse the repository at this point in the history
  3. Gate useEvent handling in ExhaustiveDeps as experimental

    To keep the test simple, just imperatively only run the test if the
    EXPERIMENTAL flag is set.
    poteto committed Sep 23, 2022
    Configuration menu
    Copy the full SHA
    9550edb View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    76c096c View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    54765ee View commit details
    Browse the repository at this point in the history