tRPCttRPC
Powered by
ZephZ
tRPC•4y ago•
15 replies
Zeph

Clearing Cache

How do I clear the queryCache for a particular query using the trpc context? If that's not possible, how can I do that using queryClient?
queryClient.getQueryCache().clear()
queryClient.getQueryCache().clear()

I've tried the above but it clears the entire cache. I just want to clear the cache of particular key.

Thank you!
tRPCJoin
Move Fast & Break Nothing. End-to-end typesafe APIs made easy.
5,015Members
Resources
Recent Announcements

Similar Threads

Was this page helpful?

Similar Threads

cache craziness?
patrickPpatrick / ❓-help
3y ago
Nextjs 16 use cache
VilianVVilian / ❓-help
3mo ago
trpc + unstable_cache (Next)
LedrubLLedrub / ❓-help
2y ago
Don't understand cache
VengeanceVVengeance / ❓-help
2y ago