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
I am currently using code like below to do an optimistic update. It just doesn't seem like a very good API because I am having to duplicate the optimistic data in the mutate function and optimisticData. One place uses the data passed to the function and the other is using the original data from the initial fetch. This seems to stem from the delete fetcher not returning the new data.
Am I missing something or is this the best approach for optimistic updates with v 1.3?
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
-
I am currently using code like below to do an optimistic update. It just doesn't seem like a very good API because I am having to duplicate the optimistic data in the mutate function and optimisticData. One place uses the data passed to the function and the other is using the original data from the initial fetch. This seems to stem from the delete fetcher not returning the new data.
Am I missing something or is this the best approach for optimistic updates with v 1.3?
Beta Was this translation helpful? Give feedback.
All reactions