We are facing a weird issue in iOS. We subscribed to the _socket.Closed event to detect socket disconnect issue and try to reconnect using a new socket.
While trying this on an android phone, we are getting the event called immediately. But for iOS, it’s taking time to fire the event when I turn off the wifi of an iOS device, like 30/40 seconds.
With a combination of configuring the server and client you should be able to detect timeouts closer to when they occur. It will unfortunately never be accurate to the millisecond as timeout events are always reliant on underlying ping/pong messages and reasonable allowances for hiccups in the connection.