Using solid-element, how do you get the children of a web component?
I'm trying to get the children of a custom component created with solid-element. In plain SolidJS I would simply use
props.children
, but this is undefined on the solid-element component. Is there a particular way to get this done using solid element?4 Replies
you can access the shadowRoot of any custom element with its .shadowRoot property.
Element.shadowRoot - Web APIs | MDN
The Element.shadowRoot read-only property
represents the shadow root hosted by the element.
Thanks @lexlohr. You pointed me in the right direction.
Happy to help.