Firefox Tomorrow

web api instance property

HTMLMediaElement: ended property

View on MDN ↗

The HTMLMediaElement.ended property indicates whether the media element has ended playback.

Value

A boolean value which is true if the media contained in the element has finished playing.

If the source of the media is a MediaStream, this value is true if the value of the stream’s active property is false.

Examples

const obj = document.createElement("video");
console.log(obj.ended); // false

Specifications

SpecificationsStandards references are available on the canonical MDN page.

Browser compatibility

Browser compatibilityCompatibility data is available on the canonical MDN page.

See also