How to update previously fetched data (cache) after a PUT request. #256
-
I have a form component to update an organization data, I first fetch the org data
the data returned is used to fill out the organization form as initial values to be updated. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Yes, you can use |
Beta Was this translation helpful? Give feedback.
Yes, you can use
queryCache.setQueryData
- see https://github.com/tannerlinsley/react-query#query-updates-from-mutations