-
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Can't understand what you want to do. When the WebSocket connection is established, the If server closes the WebSocket connection first, only |
Beta Was this translation helpful? Give feedback.
Can't understand what you want to do.
When the WebSocket connection is established, the
Promise
will be resolved. A settledPromise
can't switch to other states anymore.If server closes the WebSocket connection first, only
close
event will fire, and the listener for that event will close both thereadable
andwritable
streams.connect.tsx
knows this because the pipe chain will stop anddevice.disconnected
will be resolved.