T
TanStack2y ago
united-yellow

useQuery vs useMutation

Hello!! I would like your opinion and how you handle the following scenario. when you want to perform an API call on a button click do you use useQuery refetch option or you go for useMutation? if useMutation is the way to go, when you call the refetch on useQuery what are the cases?
1 Reply
harsh-harlequin
harsh-harlequin2y ago
for Get requests, useQuery will be used

Did you find this page helpful?