useConnectionState
The useConnectionState
hook allows you to simply implement your own ConnectionState
component.
Import
import { useConnectionState } from "@livekit/components-react";
Usage
const connectionState = useConnectionState(room);
Properties
room?
Room
Returns
import("livekit-client").ConnectionState;