Get started
Quick start
1. Wrap your app
tsxmain.tsx · _app.tsx · layout.tsx
import { DecaneKit } from "decane-connect-kit";
<DecaneKit config={{ theme: "auto" }}>
<App />
</DecaneKit>That’s the entire setup. Wallet discovery starts immediately. If the user was previously connected, the session is restored from localStorage automatically.
2. Add a connect button
tsx
import { useDecane, useWalletSelector } from "decane-connect-kit";
function ConnectButton() {
const { isConnected, connectedWallet, disconnect } = useDecane();
const { open } = useWalletSelector();
if (isConnected) return (
<>
<span>{connectedWallet!.name}</span>
<button onClick={disconnect}>Disconnect</button>
</>
);
return <button onClick={open}>Connect Wallet</button>;
}i
The modal renders itself — there is no <WalletSelector> component to place anywhere.
3. Sign a message
tsx
import { useSignMessage } from "decane-connect-kit";
const { signMessage, signature, loading, error } = useSignMessage();
await signMessage("Hello world");