The layer() CSS function is used along with the @import at-rule to put the imported resource in a separate named cascade layer.
Syntax
@import url layer(layer-name);
@import "dark.css" layer(framework.themes.dark);
The framework.themes.dark is the layer into which the CSS file would be imported.
Formal syntax
Specifications
Browser compatibility
See also
- @import
- CSS at-rule functions
- CSS cascading and inheritance module
来源:MDN Web Docs / Mozilla 贡献者 · 作者与贡献记录 · CC BY-SA 2.5。离线整理了版式、链接和媒体显示。
