getProvider
Action for accessing Client
's ethers Provider.
import { getProvider } from '@wagmi/core'
Usage
import { getProvider } from '@wagmi/core'
const provider = getProvider()
Return Value
Provider
Configuration
chainId (optional)
Force a specific chain id. The wagmi Client
's ethers provider
must be set up as a chain-aware function for this to work correctly.
import { getProvider } from '@wagmi/core'
const provider = getProvider({
chainId: 1,
})