worker-dom icon indicating copy to clipboard operation
worker-dom copied to clipboard

Shadow DOM

Open trusktr opened this issue 5 years ago • 2 comments

I see attachShadow is listed as a feature that will not be supported in the table.

It would be awesome though! But I can see how complex it would be.

If it existed in the future, I would love to try it with OffscreenCanvas in http://lume.io. The Lume elements use Shadow DOM.

trusktr avatar May 05 '20 18:05 trusktr

I work on a Web Component project and I would also be interested in seeing Shadow DOM (and related Custom Element APIs) support! I'm curious, what is the reason(s) Custom Element APIs are intentionally not supported?

nicholasrice avatar Nov 30 '20 18:11 nicholasrice

The reason is probably that ShadowDOM is complex to implement. I wonder if sticking a polyfill into the worker might work. I wonder, because the polyfill relies on the existing DOM APIs and patching their prototypes or similar. So in theory, if the same APIs exist in worker-dom and the polyfill can patch them, then it might work, or at least might require smaller modifications to worker-dom than trying to make a new ShadowDOM implementation in worker-dom...

trusktr avatar Jul 08 '21 17:07 trusktr