MobileWalletProvider
Wrap your app’s root component withMobileWalletProvider from @wallet-ui/react-native-web3js. This provider manages the wallet connection state and exposes the useMobileWallet hook to all child components.
App.tsx
Props
| Prop | Type | Description |
|---|---|---|
chain | string | The Solana cluster to connect to (e.g. 'solana:devnet', 'solana:mainnet-beta'). |
endpoint | string | The RPC endpoint URL for the cluster. |
identity | object | Your app’s identity shown to the user during wallet authorization. |
Identity object
| Field | Type | Description |
|---|---|---|
name | string | Your app’s display name. |
uri | string | Your app’s website URL. |
icon | string | Path to your app icon, relative to uri. |
useMobileWallet hook
Inside any component wrapped byMobileWalletProvider, use the useMobileWallet hook to access wallet functionality:
Next steps
Quickstart
See usage examples for all useMobileWallet hook methods.
