Whether the WebSocket is currently connected.
bool isConnected() => _state == WebSocketState.connected;