/

HTML / CSS / JavaScript Tutorial

HTML Standard attribute: scoped

[this page | pdf | back links]

The HTML scoped attribute indicates that styles in a <style> element only apply to the element’s parent and that element’s child elements. The aim is to allow style declarations that apply only to individual parts of a HTML document, but currently it does not always work with major browsers.

 

Valid attribute values (when used with <style> elements) include:

 

Value

Description

scoped

Styles only apply to element’s parent element and that element’s child elements

 


NAVIGATION LINKS
Contents | Prev | Next | HTML Attributes


Desktop view | Switch to Mobile