getQueryKey
We provide a getQueryKey helper that accepts a router or procedure so that you can easily provide the native function the correct query key.
tsx
tsx
note
The query type any will match all queries in the cache only if the react query method where it's used uses fuzzy matching. See TanStack/query#5111 (comment) for more context.
tsx
tsx