Skip to content
Discussion options

You must be logged in to vote

as you've already found out - onMutate runs before the mutateFn. Both functions are not "receiving" any data - you are reading them from the cache. so if the function that runs first writes data to the cache, I think it's okay that if the function that runs after that will get the latest value if it reads it from that cache.

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@nandcello
Comment options

@TkDodo
Comment options

@nandcello
Comment options

@TkDodo
Comment options

Answer selected by nandcello
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants