Docs

ThirdwebSDKProvider

The ThirdwebSDKProvider is used when you want to provide your own wallet connection logic and just use the thirdweb SDK to interact with smart contracts and the blockchain. This means you can use everything in the SDK except for wallet connection-related components and hooks. if you need those please use the ThirdwebProvider instead.

ThirdwebSDKProvider allows you to set a provider & signer to the Thirdweb SDK.

Example

Wrap your app in the ThirdwebSDKProvider to access the SDK’s functionality from anywhere in your app.

import { ThirdwebSDKProvider } from "@thirdweb-dev/react";
import { ethers } from "ethers";
// Example shows how to get the signer from the injected provider ( wallet extension )
function Example() {
return (
<ThirdwebSDKProvider
activeChain="ethereum"
clientId="YOUR_CLIENT_ID"
signer={new ethers.providers.Web3Provider(window.ethereum).getSigner()}
>
<App />
</ThirdwebSDKProvider>
);
}

Parameters

Returns