CSS:paintWorklet 静态属性
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
值
关联的 Worklet
对象。
示例
以下示例演示了通过特性检测从 js 文件加载绘制 worklet。
js
if ("paintWorklet" in CSS) {
CSS.paintWorklet.addModule("checkerboard.js");
}
规范
Specification |
---|
CSS Painting API Level 1 # ref-for-dom-css-paintworklet |
浏览器兼容性
BCD tables only load in the browser