Skip to content

Instantly share code, notes, and snippets.

@Ms2ger
Last active February 27, 2017 13:13
Show Gist options
  • Save Ms2ger/d1a5160f52da34c6fee7aa53f01addcc to your computer and use it in GitHub Desktop.
Save Ms2ger/d1a5160f52da34c6fee7aa53f01addcc to your computer and use it in GitHub Desktop.

The ended event is fired when playback or streaming has stopped because the end of the media was reached or because no further data is available.

This event occurs in three related but unique contexts.

Media elements (<audio> and <video>)

The ended event is fired at <audio> and <video> when playback reaches the end of the media.

Specification
    HTML5 media
Interface
    `Event` (Should be a link)
Bubbles
    No
Cancelable
    No
Target
    `HTMLMediaElement`
Default Action
    None.

Media streams' tracks

The ended event is fired at media streams' tracks, which use the MediaStreamTrack interface, when the track's source permanently stops sending data on the stream. There are various ways this can happen, including: …

Specification
    Media Capture and Streams
Interface
    `Event`
Bubbles
    No
Cancelable
    No
Target
    `MediaStreamTrack`
Default Action
    None.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment