agw-react
AbstractWalletProvider
The AbstractWalletProvider component is a wrapper component that provides the Abstract Global Wallet context to your application, allowing you to use hooks and components.
Wrap your application in the AbstractWalletProvider
component to enable the use of the package’s hooks and components
throughout your application.
import { AbstractWalletProvider } from "@abstract-foundation/agw-react";
const config = {
testnet: true, // Required
// Optionally, provide your own RPC URL
// Learn more: https://viem.sh/docs/clients/transports/http.html
// transport: http("https://.../rpc") // Optional
};
const App = () => {
return (
<AbstractWalletProvider config={config}>
{/* Your application components */}
</AbstractWalletProvider>
);
};
Props
config
object
requiredThe configuration object for the AbstractWalletProvider.
Was this page helpful?