How can I reset query cache without refetching it?
I’m trying to remove data from cache and not refetch it. I have tried reset and refetch queries.
They don’t seem to work right.
6 Replies
exotic-emeraldOP•10mo ago
Can I get help here please?
conventional-tan•10mo ago
you are probably still subscribed to the query when you refetch it
exotic-emeraldOP•10mo ago
I’ve gone through the documentation several times and it seems there’s no way to just clear a particular cache
Without performing refetch after
vicious-gold•10mo ago
Refetching only happens when you manually refetch, or there is a subscriber.
A useQuery is probably subscribed as vossmalte mentioned
adverse-sapphire•10mo ago
queryClient.removeQueries
?adverse-sapphire•10mo ago
TanStack | High Quality Open-Source Software for Web Developers
Headless, type-safe, powerful utilities for complex workflows like Data Management, Data Visualization, Charts, Tables, and UI Components.
