Using urql together with TanStack Query / React Query #3771
|
I'm wondering if it's a bad idea to use urql together with TanStack Query, instead of with urql's own React bindings. This is attractive because TS Query can be used for other async requests such as REST APIs, device geolocation API, etc. On the other hand, I would hate to have to include urql's React bindings in addition to TS Query in the bundle if that cannot be avoided. A further point of complication is that in my particular case, I am using Next.js. |
Answered by
JoviDeCroock
Apr 11, 2025
Replies: 1 comment
|
|
0 replies
Answer selected by
JoviDeCroock
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@urql/corewith just afetchexchange is probably a great idea to use with TanStack query as the bundle size is really low. You'll have to decide whether to useurqlor a normalfetchdepending on the request but apart from that it sounds like it should work.