UNPKG

@safe-global/safe-react-hooks

Version:

A collection of React Hooks that facilitates the interaction of React apps with Safe Smart Accounts

12 lines (11 loc) 609 B
import { type UseQueryResult } from '@tanstack/react-query'; import type { ConfigParam, SafeConfig } from '../../types/index.js'; export type UseThresholdParams = ConfigParam<SafeConfig>; export type UseThresholdReturnType = UseQueryResult<number>; /** * Hook to get the connected Safe's threshold. * @param params Parameters to customize the hook behavior. * @param params.config SafeConfig to use instead of the one provided by `SafeProvider`. * @returns Query result object containing the Safe's threshold. */ export declare function useThreshold(params?: UseThresholdParams): UseThresholdReturnType;