Interface representing a provider for interacting with Ethereum-compatible wallets.

interface Provider {
    request: Eip1193A.RequestMethod;
    on: Eip1193A.OnMethod;
    removeListener(eventName: string, listener: ((...args: unknown[]) => unknown)): Eip1193A.Provider;
}

Properties

Methods

Properties

Sends a request to the provider.

Adds an event listener to the provider.

Methods

  • Removes an event listener from the provider.

    Parameters

    • eventName: string

      The name of the event to remove the listener from.

    • listener: ((...args: unknown[]) => unknown)

      The listener function to remove.

        • (...args): unknown
        • Parameters

          • Rest...args: unknown[]

          Returns unknown

    Returns Eip1193A.Provider

    The provider instance.