import { useWalletKitLink } from "@walletkit/react-link";
import { parseEther } from "viem";
export function App() {
const walletKit = useWalletKitLink();
const [hash, setHash] = useState("");
const sendTransaction = async () => {
const hash = await walletKit.signAndSendTransactions([
{
to: "0xc6FfEB1298Eb33Da430d14e5Eb789256ec344625",
value: parseEther("0.01"),
},
]);
setHash(hash);
};
return (
<div>
<button onClick={() => sendTransaction()}>Send Transaction</button>
{hash ? <div>Transaction: {hash}</div> : null}
</div>
);
}