You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I encountered this issue when trying to use useQuery in a composable. Maybe I'm missing something too. Otherwise, it seems to me that it would contradict Composition API pattern.
Could you use useClientHandle instead? This one works outside components, but it is intended for one shot queries...
Describe the bug
The setup: There's a pinia store that is used in a router guard, the store uses
useQuery
composable from@urql/vue
Because it tried to access vue instance in router guard the app returns the following error:
As far as I can see the error comes from
urql/packages/vue-urql/src/useClient.ts
Line 104 in 25d114d
Am I doing something wrong?
Reproduction
https://stackblitz.com/edit/vitejs-vite-kudyigng
Urql version
@urql/vue v1.4.2
Validations
The text was updated successfully, but these errors were encountered: