Esente4mo ago

How to know when a Deno.Conn is closed

A Deno.Conn is created either with Deno.connectTls or Deno.connect. How do we detect when the connection is closed to handle appropriately? I think I can getReader from the conn's readable and use the closed promise there, but my plan is to pass along the readable so I try not to acquire a lock on that reader.
0 Replies
No replies yetBe the first to reply to this messageJoin