Creates a new TwitchEmbed instance.
The div HTML element where the player will appear.
The player initialization options.
The div HTML element where the player will appear.
The player options that were provided when the instance was constructed.
Adds an event listener for the given event.
The event type to which the listener should react.
The logic that should happen when the listener fires.
Disables the captions for the content that is currently playing.
Enables the captions for the content that is currently playing.
Returns the channel’s name. Works only for live streams, not VODs.
Returns the channel’s identifier. Works only for live streams, not VODs.
Returns the name of the collection currently being played.
Returns the current video’s timestamp, in seconds. Works only for VODs, not live streams.
Returns the duration of the video, in seconds. Works only for VODs,not live streams.
Returns true if the live stream or VOD has ended; otherwise, false.
Returns true if the player is muted; otherwise, false.
Retrieves the playback statistics for this player. The statistics contain information such as video FPS, resolution, latency and dropped frames.
Returns the Twitch.Player object. Can be used for more fine-grained control of the player.
Returns the available video qualities. For example, chunked (pass-through of the original source).
Returns the current quality of video playback.
Returns the video ID. Works only for VODs, not live streams.
Returns the volume level, a value between 0.0 and 1.0.
Returns true if the video is paused; otherwise, false. Buffering or seeking is considered playing.
Pauses the player.
Begins playing the specified video.
Seeks to the specified timestamp (in seconds) in the video and resumes playing if paused. Does not work for live streams.
The specified timestamp (in seconds).
Sets the channel to be played.
The selected channel.
Sets the channel to be played.
The selected channel's identifier.
Sets the collection to be played. Optionally also specifies the video within the collection, from which to start playback. If a video ID is not provided here or the specified video is not part of the collection, playback starts with the first video in the collection.
The identifier for the collection.
The identifier for the video.
If true, mutes the player; otherwise, unmutes it. This is independent of the volume setting.
If true, player will be muted. Otherwise, it will be unmuted.
Sets the quality of the video. quality should be a string value returned by getQualities.
The quality to be set.
Sets the video to be played to be played and starts playback at timestamp (in seconds).
The identifier of the video to be played.
The spot where the playback will be started (in seconds).
Sets the volume to the specified volume level, a value between 0.0 and 1.0.
A number between 0 and 1.
Generated using TypeDoc
A TS wrapper for the Twitch interactive media player, that can also include the chat.