method WebSocket.addEventListener
WebSocket.addEventListener<K extends keyof WebSocketEventMap>(type: K,listener: (this: WebSocket,ev: WebSocketEventMap[K],) => any,options?: boolean | AddEventListenerOptions,): void
K extends keyof WebSocketEventMap
type: K
listener: (this: WebSocket,ev: WebSocketEventMap[K],) => any
optional
options: boolean | AddEventListenerOptions
void
WebSocket.addEventListener(type: string,listener: EventListenerOrEventListenerObject,options?: boolean | AddEventListenerOptions,): void
listener: EventListenerOrEventListenerObject
optional
options: boolean | AddEventListenerOptions
void