Properties
Optional WebSocketConstructor
WebSocketConstructor?: {
CLOSED: 3;
CLOSING: 2;
CONNECTING: 0;
OPEN: 1;
prototype: WebSocket;
new (url, protocols?): WebSocket;
}
Type declaration
- new (url, protocols?): WebSocket
Parameters
- url: string | URL
Optional protocols: string | string[]
Returns WebSocket
Readonly CLOSED: 3
Readonly CLOSING: 2
Readonly CONNECTING: 0
Readonly OPEN: 1
prototype: WebSocket
Optional fetch
fetch?: ((input, init?) => Promise<Response>)
Type declaration
- (input, init?): Promise<Response>
Parameters
- input: RequestInfo | URL
Optional init: RequestInit
Returns Promise<Response>
Optional rpc
url
url: string
Optional websocket
websocket?: WebsocketClientOptions & {
url?: string;
}
MDN Reference