Skip to content

Commit 05a8057

Browse files
authored
docs: Note that calling setQueryData triggers onSuccess (#2808)
1 parent 255f7c6 commit 05a8057

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/src/pages/reference/useQuery.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ const result = useQuery({
136136
- If set to `['isStale']` for example, the component will not re-render when the `isStale` property changes.
137137
- `onSuccess: (data: TData) => void`
138138
- Optional
139-
- This function will fire any time the query successfully fetches new data.
139+
- This function will fire any time the query successfully fetches new data or the cache is updated via `setQueryData`.
140140
- `onError: (error: TError) => void`
141141
- Optional
142142
- This function will fire if the query encounters an error and will be passed the error.

0 commit comments

Comments
 (0)