This guide is for Hooks Only (Headless), as the Dynamic Widget UI component already displays the wallets for you.
Fetch available wallets
You can find the list of available wallets in thewalletOptions
prop returned by the useWalletOptions hook.
When browsing wallets in the Dynamic Widget, you might see labels beside them like “Last Used”, “Multichain” or “Recommended”.Last used comes from the “dynamic_last_used_wallet” value in localstorage.
“Multichain” comes from the
chainGroup
node in each wallet (Remember to also add the WalletConnectors for each chain).
“Recommended” from the Recommended Wallets feature.Display a wallet icon
Use the@dynamic-labs/wallet-book
library to display a wallet icon using the exported WalletIcon
component. This component takes a walletKey
prop, which is the key of the wallet you want to display.