You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In our project we would need access to it, or at least to the "isInvalidated" property.
The reason is, that our refresh-logic is delayed (invalidate from web-socket-msg with refetchType "none" and cancelRefetch false) so we only return a number here if either the current state is invalidated or the revertState is, effectively making 2 refetches for a change (but maybe skipping 10-100 refetches would otherwise happen if we refetched on every web-socket-msg), because otherwise we can't be sure to have gotten the latest data when the web-socket-msgs finally stop dripping in.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
``Hello, in react-query v4 the revertState was accessible for example in a refetchInterval function. But in v5 it is "hash-private" https://github.com/TanStack/query/blob/main/packages/query-core/src/query.ts#L170 so we can't access it anymore
In our project we would need access to it, or at least to the "isInvalidated" property.
The reason is, that our refresh-logic is delayed (invalidate from web-socket-msg with refetchType "none" and cancelRefetch false) so we only return a number here if either the current state is invalidated or the revertState is, effectively making 2 refetches for a change (but maybe skipping 10-100 refetches would otherwise happen if we refetched on every web-socket-msg), because otherwise we can't be sure to have gotten the latest data when the web-socket-msgs finally stop dripping in.
Beta Was this translation helpful? Give feedback.
All reactions