socket.io icon indicating copy to clipboard operation
socket.io copied to clipboard

Expose io state

Open andrejleitner opened this issue 4 years ago • 1 comments

Just an idea, would it make sense to expose (properly typed) socket.io._readyState? There should be 3 possible values: 'closed' | 'opening' | 'open'.

andrejleitner avatar Jul 12 '21 20:07 andrejleitner

That's a good question! For the record, it was simply called readyState in Socket.IO v2.

I'm not against making it public though. Do you have a specific use case for this?

darrachequesne avatar Jul 13 '21 06:07 darrachequesne