Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
method WebSocket.prototype.close

Closes the WebSocket connection, optionally using code as the the WebSocket connection close code and reason as the the WebSocket connection close reason.

Parameters

optional
code: number
optional
reason: string