<canvas id="canvas" width="200" height="200" layoutsubtree>
<div id="child" style="width: 100px; height: 100px; backdrop-filter: blur(1px);">
hello world
</div>
</canvas>
<script>
canvas.onpaint = () => {
const ctx = canvas.getContext('2d');
ctx.reset();
// draw stripes
for (let y = 0; y < canvas.height; y++) {
ctx.fillStyle = (y % 2 === 0) ? 'black' : 'white';
ctx.fillRect(0, y, canvas.width, 1);
}
// draw #child into the canvas.
ctx.drawElementImage(child, 50, 50);
}
canvas.requestPaint();
</script>