Type alias WatchBlockNumberParameters<TTransport>

WatchBlockNumberParameters<TTransport>: {
    onBlockNumber: OnBlockNumberFn;
    onError?: ((error) => void);
} & (GetTransportConfig<TTransport>["type"] extends "webSocket"
    ? {
        emitMissed?: never;
        emitOnBegin?: never;
        poll?: false;
        pollingInterval?: never;
    } | PollOptions & {
        poll: true;
    }
    : PollOptions & {
        poll?: true;
    })

Type Parameters

Type declaration

  • onBlockNumber: OnBlockNumberFn

    The callback to call when a new block number is received.

  • Optional onError?: ((error) => void)
      • (error): void
      • The callback to call when an error occurred when trying to get for a new block.

        Parameters

        Returns void

Generated using TypeDoc