Jack Fischer
Jack Fischer2y ago

`QueryClientProvider` not included in `withTRPC`?

Trying to use import { useIsMutating } from "react-query" but it's throwing Error: No QueryClient set, use QueryClientProvider to set one We have the trpc.withTRPC(MyApp) with Next.js to add the tRPC provider - expected that this wouldn't also add the QueryClientProvider?
2 Replies
TkDodo 🔮
TkDodo 🔮2y ago
With v10 of trpc, you need v4 of react-query, so the import must come from @tanstack/react-query
Jack Fischer
Jack FischerOP2y ago
Beast thank you!