Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Corrected the "Observing cache behaviour" example point no.4 #4174

Merged
merged 2 commits into from
Feb 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/rtk-query/usage/queries.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ This example demonstrates request deduplication and caching behavior:
2. A second later, another `Pokemon` component is rendered with 'bulbasaur'
- Notice that this one doesn't ever show 'Loading...' and no new network request happens? It's using the cache here.
3. A moment after that, a `Pokemon` component for 'pikachu' is added, and a new request happens.
4. When you click 'Refetch' of a particular pokemon type, it'll update all of them with one request.
4. When you click 'Refetch' for a specific `Pokemon`, it'll update all instances of that `Pokemon` with one request.

:::note Try it out
Click the 'Add bulbasaur' button. You'll observe the same behavior described above until you click the 'Refetch' button on one of the components.
Expand Down