React Api Reference
    Preparing search index...

    Function AudioPlayer

    • AudioPlayer is a component responsible for rendering a participant’s audio or screen-share audio stream.

      Parameters

      • option: { participantId: string; type?: "audio" | "shareAudio" }
        • participantId: string

          Unique ID of the participant whose audio stream is rendered.

        • Optionaltype?: "audio" | "shareAudio"

          Type of audio stream to render ("audio" or "shareAudio"). Defaults to "audio".

      Returns Element

      A JSX element that plays the requested audio stream.

      import { AudioPlayer } from "@videosdk.live/react-sdk";

      <AudioPlayer
      participantId={participantId}
      type="audio"
      />;