onSuccess only on fetching #4067
Unanswered
dstoyanoff
asked this question in
General
Replies: 1 comment 2 replies
-
This behaviour has been changed in v4: |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I am trying to implement the following:
I have a query that gets data from the backend. When the data is resolved, I subscribe to a SignalR endpoint to get updates and modify the cache using
setQueryData
. The problem is thatsetQueryData
would also callonSuccess
, going into an infinite loop. Same withonSettled
. Is there a place where I can attach only to the initial query (either network or resolved from the cache), but not to updates coming from manual cache updates?Beta Was this translation helpful? Give feedback.
All reactions