(method: string, params: Record<string, any> = {})
| 31 | constructor(ws: WebSocket, private reconnect?: () => Promise<WebSocket>) { |
| 32 | this.ws = ws; |
| 33 | this.attach(ws); |
| 34 | } |
| 35 | |
| 36 | onEvent(handler: (event: PushEvent) => void): void { |
| 37 | this.eventHandlers.push(handler); |
| 38 | } |
| 39 | |
| 40 | onDisconnect(handler: (reason: string) => void): void { |
| 41 | this.disconnectHandlers.push(handler); |
| 42 | } |
no outgoing calls
no test coverage detected