ProcessingInstruction:sheet 属性

sheet 属性是 ProcessingInstruction 接口的一个只读属性,它包含了与该 ProcessingInstruction 相关联的样式表信息。

处理指令 xml-stylesheet 常用于在 XML 文件中关联样式表。

关联的 Stylesheet 对象,如果没有,则为 null

示例

xml
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="rule.css"?>

处理指令的 sheet 属性将返回描述 rule.cssStyleSheet 对象。

规范

Specification
CSS Object Model (CSSOM)
# dom-linkstyle-sheet

浏览器兼容性

BCD tables only load in the browser

参见