Skip to content

Commit

Permalink
tidy up
Browse files Browse the repository at this point in the history
  • Loading branch information
subject026 committed Oct 9, 2024
1 parent 9c48bdf commit 81d29dd
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions src/app/HomePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,25 +18,22 @@ export function HomePage() {
const { connectors } = useConnect();
const { chains, switchChain } = useSwitchChain();

console.log({ account });
console.log({ account });
console.log({ account });
console.log({ account });
console.log({ account });

return (
<div>
{account.status === "connected" ? (
<div>
<div>
<div className="p-2">
<span>{account.address}</span>
<button onClick={() => disconnect()}>disconnect</button>
</div>

<div>
<div className="p-2">
<span>{account.chain?.name}</span>
<button onClick={() => switchChain({ chainId: 31337 })}>
switch to anvil
<button
className="px-2 py-1 bg-neutral-300 text-neutral-800 rounded"
onClick={() => switchChain({ chainId: 31337 })}
>
switch to foundry
</button>
</div>
<Balance account={account.address} chainId={account.chainId} />
Expand Down

0 comments on commit 81d29dd

Please sign in to comment.