MCPcopy Index your code
hub / github.com/websockets/ws / pause

Method pause

lib/websocket.js:347–357  ·  view source on GitHub ↗

* Pause the socket. * * @public

()

Source from the content-addressed store, hash-verified

345 * @public
346 */
347 pause() {
348 if (
349 this.readyState === WebSocket.CONNECTING ||
350 this.readyState === WebSocket.CLOSED
351 ) {
352 return;
353 }
354
355 this._paused = true;
356 this._socket.pause();
357 }
358
359 /**
360 * Send a ping.

Callers 3

createWebSocketStreamFunction · 0.80
socketOnDataFunction · 0.80
websocket.test.jsFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected