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
Inside the global MutationCacheonError callback I use axios to forward the error to our backend. Now, in an offline case I'd like to cache this request on the client and send it once the client is back online again. Normally I use react-query and paused mutations to do this but I'm not sure if that's possible inside the onError callback. Is it possible to use react-query itself to create a (potentially paused) mutation inside MutationCache.onError.
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.
-
Inside the global
MutationCache
onError
callback I use axios to forward the error to our backend. Now, in an offline case I'd like to cache this request on the client and send it once the client is back online again. Normally I use react-query and paused mutations to do this but I'm not sure if that's possible inside theonError
callback. Is it possible to use react-query itself to create a (potentially paused) mutation insideMutationCache.onError
.Beta Was this translation helpful? Give feedback.
All reactions