MDN self-hosted library · e01.org

HTMLEmbedElement: type property

HTML DOM

Open notebook · 1 cells web-api-instance-property upstream source

HTML DOM

The type property of the HTMLEmbedElement interface returns a string that reflects the type attribute of the embed element, indicating the MIME type of the resource. It reflects the embed element's type attribute

Value

A string; the MIME type of the resource.

Examples

const el = document.getElementById("el");
console.log(el.type); // Output: "video/webp"

Specifications

Browser compatibility

See also