• Hook for accessing the active Chain the current wallet is connected to

    import { useChain } from "@thirdweb-dev/react-core"
    

    Returns Chain | undefined

    Example

    You can get the chain of the connected wallet by using the hook as follows:

    import { useChain } from "@thirdweb-dev/react-core"

    const App = () => {
    const chain = useChain()

    return <div>{chain.chainId}</div>
    }

    See

    Documentation

Generated using TypeDoc