Skip to content

Commit 4e6432a

Browse files
authored
docs: Enrich the onMutate description for context (#8710)
1 parent 92e5672 commit 4e6432a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/framework/react/reference/useMutation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ mutate(variables, {
6060
- Optional
6161
- This function will fire before the mutation function is fired and is passed the same variables the mutation function would receive
6262
- Useful to perform optimistic updates to a resource in hopes that the mutation succeeds
63-
- The value returned from this function will be passed to both the `onError` and `onSettled` functions in the event of a mutation failure and can be useful for rolling back optimistic updates.
63+
- The value returned from this function will be passed to the `onSuccess`, `onError`, and `onSettled` functions and can be useful for rolling back optimistic updates.
6464
- `onSuccess: (data: TData, variables: TVariables, context?: TContext) => Promise<unknown> | unknown`
6565
- Optional
6666
- This function will fire when the mutation is successful and will be passed the mutation's result.

0 commit comments

Comments
 (0)