UNPKG

@gnosis.pm/dapp-ui

Version:

Web3 provider setup functions built with Typescript and love. From Gnosis.

12 lines 736 B
import { MetamaskProvider } from '../provider/types'; export declare const MetamaskSubscriptionsSymbol: unique symbol; export interface MetamaskSubscriptions { [MetamaskSubscriptionsSymbol]: true; onAccountsChanged(callback: (accounts: string[]) => void, once?: boolean): () => void; onNetworkChanged(callback: (networkId: string) => void, once?: boolean): () => void; onData(callback: (error: Error | null, payload: any) => void, once?: boolean): () => void; onError(callback: (message: string) => void, once?: boolean): () => void; } declare const createMetamaskSubscriptions: (provider: MetamaskProvider) => MetamaskSubscriptions; export default createMetamaskSubscriptions; //# sourceMappingURL=metamask.d.ts.map