Document.preferredStyleSheetSet

翻译不完整。 请帮助我们翻译这篇文章!

preferredStyleSheetSet 属性会依网页作者的喜好回传阶层样式集。

语法

preferredStyleSheetSet = document.preferredStyleSheetSet

preferredStyleSheetSet 指的是作者偏好的阶层样式集。内容取决于阶层样式集的次序与 Default-Style HTTP 标头内容.

如果作者没有定义偏好的阶层样式集,就会回传空白的("")字符串。

范例

if (document.preferredStyleSheetSet) {
  console.log("The preferred style sheet set is: " + document.preferredStyleSheetSet);
} else {
  console.log("There is no preferred style sheet.");
} 

规范

浏览器相容性

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
preferredStyleSheetSet
DeprecatedNon-standard
Chrome No support NoEdge No support NoFirefox Full support 3IE No support NoOpera ? Safari No support NoWebView Android No support NoChrome Android No support NoFirefox Android Full support 4Opera Android ? Safari iOS No support NoSamsung Internet Android No support No

Legend

Full support  
Full support
No support  
No support
Compatibility unknown  
Compatibility unknown
Non-standard. Expect poor cross-browser support.
Non-standard. Expect poor cross-browser support.
Deprecated. Not for use in new websites.
Deprecated. Not for use in new websites.

参见