@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) • 610 B
TypeScript
import type { Address } from 'viem';
import { ConfigParam, SafeConfigWithSigner } from '../types/index.js';
export type UseSignerAddressParams = ConfigParam<SafeConfigWithSigner>;
export type UseSignerAddressReturnType = Address | undefined;
/**
* Hook to get the configured signer's address.
* @param params Parameters to customize the hook behavior.
* @param params.config SafeConfig to use instead of the one provided by `SafeProvider`.
* @returns Signer address or `undefined` if not available.
*/
export declare function useSignerAddress(params?: UseSignerAddressParams): UseSignerAddressReturnType;