Document.preferredStyleSheetSet
preferredStyleSheetSet
属性会依网页作者的喜好回传阶层样式集。
语法
preferredStyleSheetSet = document.preferredStyleSheetSet
preferredStyleSheetSet
指的是作者偏好的阶层样式集。内容取决于阶层样式集的次序与 Default-Style
HTTP 标头内容。
如果作者没有定义偏好的阶层样式集,就会回传空白的 ("") 字符串。
范例
js
if (document.preferredStyleSheetSet) {
console.log(
"The preferred style sheet set is: " + document.preferredStyleSheetSet,
);
} else {
console.log("There is no preferred style sheet.");
}
规范
浏览器相容性
Report problems with this compatibility data on GitHubdesktop | mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
preferredStyleSheetSet |
Legend
Tip: you can click/tap on a cell for more information.
- Full support
- Full support
- No support
- No support
- Non-standard. Check cross-browser support before using.
- Deprecated. Not for use in new websites.
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.