Function useAccountRefresh

Returns a Tanstack useMutation object for re-fetching the current user's Account.

const { isPending, data: user } = useAccount();
const { mutate } = useAccountRefresh();

...

useEffect(() => {
mutate();
}, [foo, bar]);