higgsboz
TTCTheo's Typesafe Cult
•Created by kdiffin on 5/6/2023 in #questions
running a query only if a boolean is true
^ Correct
12 replies
TTCTheo's Typesafe Cult
•Created by Tom on 5/3/2023 in #questions
Fire trpc useQuery only when a callback is called
You should be able to accomplish this using 2 things.
1. Set
enabled: false
in the query options
2. Call tournamentQuery.refetch
in your useEffect
when your condition is true
6 replies
TTCTheo's Typesafe Cult
•Created by Radu on 5/8/2023 in #questions
Aborting a T3 mutation
Have you attempted doing this? https://trpc.io/docs/client/aborting-procedure-calls
3 replies
TTCTheo's Typesafe Cult
•Created by kdiffin on 5/6/2023 in #questions
running a query only if a boolean is true
To expand on the above,
enabled: false
just means that useQuery will not fire on mount. You can still call refetch()
and it'll pull you're data12 replies