t
tRPC
t
tRPC
Avoid getting data on mount ( because some filters are not ready yet )
Original message was deleted
tRPC
Join
Move Fast & Break Nothing. End-to-end typesafe APIs made easy.
5,111
Members
View on Discord
K
Kliton
Is there a way to do that?
A
Ahmed Elsakaan
•
10/26/22, 4:44 PM
you can set enabled to false and destructure refetch out which is then called whenever you manually want to fetch the query
A
Ahmed Elsakaan
•
10/26/22, 4:45 PM
const
{ refetch
}
= trpc
.greeting
.useQuery
(
{ name
:
'John
'
}
,
{ enabled
: false
}
)
;
A
Ahmed Elsakaan
•
10/26/22, 4:45 PM
something like that