mokyuM
Denoβ€’3y agoβ€’
1 reply
mokyu

When the destination server is down, WebSocketStream stops and the program crashes.

I'm running the following code:
const ws = new WebSocketStream("wss://localhost");

setInterval(() => {
  console.log("test...");
}, 500);

When the localhost server is down, the code crashes and stops. With a normal WebSocket, it continues to run without stopping. How can I make it run continuously without stopping?
Was this page helpful?