Skip to main content

Interface: UseWalletReturn

Defined in: useWallet.ts:21

Return type of the useWallet hook.

Properties

PropertyTypeDescriptionDefined in
accountsWalletAccount[]All accounts from the current wallet session.useWallet.ts:29
connect(options?: any) => Promise<ConnectResult>Open the wallet modal and request user authorization. See ConnectOptions for available optionsuseWallet.ts:43
disconnect() => Promise<void>Disconnect from the wallet.useWallet.ts:45
isConnectedbooleanWhether the wallet is currently connected.useWallet.ts:33
isConnectingbooleanWhether a connection attempt is in progress.useWallet.ts:35
isReconnectingbooleanWhether the SDK is attempting a silent auto-reconnect.useWallet.ts:37
mountInline(container: HTMLElement) => Promise<void>Mount the wallet iframe inline in a DOM container instead of as a modal. The container must be a mounted DOM element (e.g., obtained via a React ref).useWallet.ts:50
selectAccount(account: WalletAccount) => Promise<void>Switch the active account.useWallet.ts:52
selectedAccountanyThe currently active account, or null if none is selected.useWallet.ts:31
walletanyThe Thru chain adapter for signing, or null if not connected. See IThruChainuseWallet.ts:27