state method

  1. @override
WebSocketState state()
override

Get the current state of the websocket

Implementation

@override
WebSocketState state() {
  return WebSocketState.values[_socket?.readyState ?? 3];
}