From ac37ef82585ce7ee2293d9677de0d937524c0c26 Mon Sep 17 00:00:00 2001 From: Corban Brook Date: Thu, 23 May 2024 12:37:13 -0400 Subject: [PATCH] examples/next: No need to wait for client side render within page (#61) --- examples/next/src/app/page.tsx | 56 ++++++++++++++-------------------- 1 file changed, 23 insertions(+), 33 deletions(-) diff --git a/examples/next/src/app/page.tsx b/examples/next/src/app/page.tsx index c5fdc509..a3eda68c 100644 --- a/examples/next/src/app/page.tsx +++ b/examples/next/src/app/page.tsx @@ -2,50 +2,40 @@ import { Box, Image, Button } from '@0xsequence/design-system' import { useOpenConnectModal } from '@0xsequence/kit' -import { useEffect, useState } from 'react' import { useAccount } from 'wagmi' import { Connected } from './components/Connected' import { Footer } from './components/Footer' export default function Home() { - const [isClient, setIsClient] = useState(false) const { isConnected } = useAccount() const { setOpenConnectModal } = useOpenConnectModal() - useEffect(() => { - setIsClient(true) - }, []) - return (
- {isClient ? ( - <> - {!isConnected ? ( - - - Next - - - Sequence Kit Logo - Sequence Kit Text Logo - - -