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

Prevent unnecessary execution of the displayValue callback in the ComboboxInput component #3048

Merged
merged 3 commits into from
Mar 21, 2024

Commits on Mar 20, 2024

  1. memoize the currentDisplayValue

    This used to be re-executed every single render. This should typically
    not be an issue, but if you use non-deterministic code (E.g.:
    `Math.random`, `Date.now`, …) then it could result in incorrect values.
    
    Using `useMemo` allows us to only re-run it if the `data.value` or thte
    `displayValue` actually changes.
    RobinMalfait committed Mar 20, 2024
    Configuration menu
    Copy the full SHA
    ff18a52 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    30dcb86 View commit details
    Browse the repository at this point in the history
  3. update changelog

    RobinMalfait committed Mar 20, 2024
    Configuration menu
    Copy the full SHA
    eed09b0 View commit details
    Browse the repository at this point in the history