Yonatan Lavy
tRPC prevents me from using revalidatePath to invalidate cache on the client
It still invalidates the cache on the server side(so on forced refresh it is shown), but doesn't invalidate the cache on my ssr rendered pages/layouts. this causes my users to be stuck and see stale data
this persists for SSR rendered pages that don't use trpc, and for when using them with a query from trpc that is being manually revalidated with trpc utils
I tried using trpc 11, also tried moving to 10.45 (latest stable) and it persists
I tried workarounds, couldn't find a way to make this happen
What am i missing? using these packages:
"@trpc/client": "^11.0.0-rc.446",
"@trpc/react-query": "^11.0.0-rc.446",
"@trpc/server": "^11.0.0-rc.446",
"@tanstack/react-query": "^5.50.0",
and this code:
https://github.com/yehonatanyosefi/trpctest
5 replies