Movatterモバイル変換


[0]ホーム

URL:


  1. Web
  2. Web APIs
  3. CSSStyleSheet
  4. rules

CSSStyleSheet: rules property

Deprecated: This feature is no longer recommended. Though some browsers might still support it, it may have already been removed from the relevant web standards, may be in the process of being dropped, or may only be kept for compatibility purposes. Avoid using it, and update existing code if possible; see thecompatibility table at the bottom of this page to guide your decision. Be aware that this feature may cease to work at any time.

rules is adeprecatedlegacy property of theCSSStyleSheet interface. Functionallyidentical to the preferredcssRules property,it provides access to a live-updating list of the CSS rules comprising thestylesheet.

Note:As a legacy property, you should not userules andshould instead use the preferredcssRules.Whilerules is unlikely to be removed soon, its availability is not aswidespread and using it will result in compatibility problems for your site or app.

Value

A live-updatingCSSRuleList containing each of the CSS rules making upthe stylesheet. Each entry in the rule list is aCSSRule objectdescribing one rule making up the stylesheet.

Specifications

Specification
CSS Object Model (CSSOM)
# dom-cssstylesheet-rules

Browser compatibility

See also

Help improve MDN

Learn how to contribute

This page was last modified on byMDN contributors.


[8]ページ先頭

©2009-2025 Movatter.jp