GitHub

Source

usePreviewDevice

Import

import { usePreviewDevice } from "@livekit/components-react";

Properties

deviceIdstring
enabledboolean
kind'videoinput' | 'audioinput'

Returns

{
selectedDevice: MediaDeviceInfo | undefined;
localTrack: T | undefined;
deviceError: Error | null;
}