useSlot should use `assignedNodes` instead of `assignedElements`
efoken opened this issue · comments
Eike Foken commented
To find also text-only Nodes which are passed in <slot />
, the useSlot
hook should use assignedNodes()
. Otherwise we only get passed HTML elements.
So it would be similar to the React children
prop.
Matias Trujillo commented
Hi, sorry for not answering earlier, if you are right and I have updated this hook to use the assignedNodes
method in version 3.11
https://webcomponents.dev/edit/RjrShAkF1NYMkBbyNOaP/src/index.jsx