import { useConnect } from "thirdweb/react";
import { createWallet } from "thirdweb/wallets";
function App() {
const { connect } = useConnect();
return (
<>
<button
onClick={() =>
connect(async () => {
const wallet = createWallet("com.coinbase.wallet", {
walletConfig: {
// choices are 'all' | 'smartWalletOnly' | 'eoaOnly'
options: "smartWalletOnly",
},
});
await wallet.connect({ client });
return wallet;
})
}
>
Connect your Smart Wallet
</button>
</>
);
}