decent-sdk
Version:
SDK for the Decent API
14 lines (13 loc) • 511 B
TypeScript
import { User } from '../../core/types/Api';
import { QueryReturn, TanstackQueryOptions } from '../types';
type FetchMeParams = TanstackQueryOptions;
type FetchMeResult = QueryReturn<User> & {
refetch: () => Promise<User | undefined>;
};
/**
* React hook to fetch the currently authenticated user.
*
* @returns {FetchMeResult} Object with { data: User, isLoading: boolean, error: Error | null, refetch: Function }
*/
export declare const useFetchMe: (params: FetchMeParams) => FetchMeResult;
export {};