You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
854 B
854 B
Class: WebSocket
⚠️ Warning: the WebSocket API is experimental and has known bugs.
Extends: EventTarget
The WebSocket object provides a way to manage a WebSocket connection to a server, allowing bidirectional communication. The API follows the WebSocket spec.
new WebSocket(url[, protocol])
Arguments:
- url
URL | string
- The url's protocol must bews
orwss
. - protocol
string | string[]
(optional) - Subprotocol(s) to request the server use.