@ably/chat - v1.4.0
    Preparing search index...

    Interface UsePresenceListenerResponse

    Common status variables for chat features. Most hooks in this library implement this interface.

    interface UsePresenceListenerResponse {
        connectionError?: ErrorInfo;
        connectionStatus: ConnectionStatus;
        error?: ErrorInfo;
        presenceData: PresenceMember[];
        roomError?: ErrorInfo;
        roomStatus: RoomStatus;
    }

    Hierarchy (View Summary)

    Index

    Properties

    connectionError?: ErrorInfo

    If there's a connection error it will be available here.

    connectionStatus: ConnectionStatus

    Provides the connection status of the Ably connection.

    error?: ErrorInfo

    The error state of the presence listener. The hook keeps presenceData up to date asynchronously, so this error state is provided to allow the user to handle errors that may occur when fetching presence data. It will be set if there is an error fetching the initial presence data, or if there is an error when fetching presence data after a presence event. The error will be cleared once a new presence event is received and successfully processed.

    presenceData: PresenceMember[]

    The current state of all the presence members, observed as a whole change, and only emitted while presence is not syncing.

    roomError?: ErrorInfo

    If there's an error with the room it will be available here.

    roomStatus: RoomStatus

    Provides the status of the room.