Replies: 1 comment
-
|
Beta Was this translation helpful? Give feedback.
0 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!
First I want to express my apologies for using Google Translate to paraphrase my question.
I'm having some problems using @tanstack/react-query+createSyncStoragePersister. I used useMutation to initiate a login request, and then cached the returned data persistently. In order to test login, I will initiate multiple requests, but the final result is that multiple pieces of data with the same mutationKey will be cached.
The result I expect is that for the same mutationKey, there will only be one piece of data. If there is new data, the old data should be updated or overwritten.
Here is part of my code:
localStorage data:
Beta Was this translation helpful? Give feedback.
All reactions