interface Player {
    config: any;
    container: HTMLElement;
    currentTimecode: string;
    currentTimestamp: number;
    live: boolean;
    version: string;
    destroy(): void;
    goBackToLive(): void;
    loadVideo(id: string): void;
    seek(time: number): void;
    setConfig(config: any): void;
    setConfig(key: string, value: any): void;
    setSrc(source: string): void;
    toggleFullScreen(): void;
    togglePlay(): void;
}

Hierarchy

  • HTMLVideoElement
    • Player

Properties

config: any

Player config

container: HTMLElement

Player's container HTMLElement

currentTimecode: string

Returns a string containing the current timecode

currentTimestamp: number

Returns an integer of the current timestamp (UTC) in milliseconds. This feature only works for DASH or HLS playlists with non-native configuration.

live: boolean

Whether the video is a live feed

version: string

Current player version

Methods

  • Destroy the player instance and remove the element from the DOM

    Returns void

  • Seek closer to live

    Returns void

  • Load a new video from the API, replacing the current video

    Parameters

    • id: string

      Video ID

    Returns void

  • Jump toward the provided time

    Parameters

    • time: number

      Time to jump to in seconds or as a timestamp

    Returns void

  • Update the player's config

    Parameters

    • config: any

    Returns void

  • Parameters

    • key: string
    • value: any

    Returns void

  • Replaces the current source

    Parameters

    • source: string

      New source

    Returns void

  • Toggle fullscreen mode

    Returns void

  • Toggle play/pause mode

    Returns void