Skip to content

Commit ebf35b9

Browse files
authored
Merge pull request #4822 from Shahzadrahim-dev/fix-doc-typo-updateQueryData
docs: fix incorrect reference to api.util.updateCachedData (should be…
2 parents a5225bf + 0954ebf commit ebf35b9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/tutorials/essentials/part-8-rtk-query-advanced.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -946,7 +946,7 @@ Like `onQueryStarted`, the [**`onCacheEntryAdded`**](https://redux-toolkit.js.or
946946
947947
`onCacheEntryAdded` will be called any time a new cache entry (endpoint + serialized query arg) is added to the cache. This means it will run less often than `onQueryStarted`, which runs whenever a request happens.
948948
949-
Similar to `onQueryStarted`, `onCacheEntryAdded` receives two parameters. The first is the usual query `args` value. The second is a slightly different `lifecycleApi` that has `{dispatch, getState, extra, requestId}`, as well as an `updateCachedData` util, an alternate form of `api.util.updateCachedData` that already knows the right endpoint name and query args to use and does the dispatching for you.
949+
Similar to `onQueryStarted`, `onCacheEntryAdded` receives two parameters. The first is the usual query `args` value. The second is a slightly different `lifecycleApi` that has `{dispatch, getState, extra, requestId}`, as well as an `updateCachedData` util, an alternate form of `api.util.updateQueryData` that already knows the right endpoint name and query args to use and does the dispatching for you.
950950
951951
There's also two additional Promises that can be waited on:
952952

0 commit comments

Comments
 (0)