Skip to content

API reference > @kontsedal/olas-realtime > ConnectionState

ConnectionState type ​

A realtime transport's connection state, as createConnectionState reports it. 'unknown' means the transport has no onConnectionChange, so the state cannot be observed. RealtimeService.onConnectionChange describes the other three.

Signature:

typescript
export type ConnectionState = 'connected' | 'reconnecting' | 'offline' | 'unknown';

Released under the MIT License.