-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Closed
Description
When using React.unstable_useDeferredValue to control a value passed down to a component then used as key by useQuery, it causes parent component (the one with the deferred hook) to rerender multiple times for no reasons. It mostly goes "crazy". The behaviour stops when removing the useQuery call or using v3.2.
It's probably because we use a pattern that should trigger an error in React (setting state in render, mutating rev cache, this kind of stuff?) but does not yet because of the unstable/experimental state of React concurrent mode.
The diff is here: v3.2.0...v3.3.0
If we remove tests and doc, diff is quite small (src/core/query.ts, useClient and useBaseQuery mosty).
How can I be of any help ?
Metadata
Metadata
Assignees
Labels
No labels