Import
Usage
Use this to react to connection changes, such as showing a loading spinner duringconnecting or an error banner.
Parameters
callback
(status: ConnectionStatus) => void
Receives 'disconnected' | 'connecting' | 'connected' | 'error'.
Subscribe to connection state changes.
connecting or an error banner.
(status: ConnectionStatus) => void
Receives 'disconnected' | 'connecting' | 'connected' | 'error'.