Usage
Using the VeChain dApp kit
1. Create the node options
1. Optional: Wallet Connect Options
import type { WalletConnectOptions } from '@vechain/dapp-kit';
const walletConnectOptions: WalletConnectOptions = {
// Create your project here: https://cloud.walletconnect.com/sign-up
projectId: '<PROJECT_ID>',
metadata: {
name: 'My dApp',
description: 'My dApp description',
// Your app URL
url: window.location.origin,
// Your app Icon
icons: [`${window.location.origin}/images/my-dapp-icon.png`],
},
};2. Initialise the DAppKit instance
Wallet Manager
Set the wallet source
Connect
State
WalletManagerState:
Subscribe to State
Subscribe to a single value in the state
Last updated
Was this helpful?