Options
All
  • Public
  • Public/Protected
  • All
Menu

wsrpc

Index

Type aliases

Handler

Handler: function

Type declaration

Message

Message: Message<__type> | object

Variables

Let WS

WS: WebSocket = WebSocket

Const version

version: string = require('../package').version

Functions

Const defaultBackoff

  • defaultBackoff(tries: number): number
  • Default backoff function. min(tries*10^2, 10 seconds)

    Parameters

    • tries: number

    Returns number

waitForEvent

  • waitForEvent<T>(emitter: EventEmitter, eventName: string | symbol): Promise<T>
  • Return a promise that will resove when a specific event is emitted.

    Type parameters

    • T

    Parameters

    • emitter: EventEmitter
    • eventName: string | symbol

    Returns Promise<T>

Generated using TypeDoc