web api instance property
HTMLIFrameElement: allowFullscreen property
The allowFullscreen property of the HTMLIFrameElement interface is a boolean value that reflects the allowfullscreen attribute of the <iframe> element, indicating whether to allow the iframe’s contents to use requestFullscreen().
[!NOTE] This property is considered a legacy property. Use
allow="fullscreen"andallowinstead.
Value
A boolean value.
Examples
<iframe id="el" allowfullscreen></iframe>
const el = document.getElementById("el");
console.log(el.allowFullscreen); // Output: true
Specifications
SpecificationsStandards references are available on the canonical MDN page.
Browser compatibility
Browser compatibilityCompatibility data is available on the canonical MDN page.
See also
- Fullscreen API
requestFullscreen()- Permissions Policy
fullscreenPermissions Policy directive