I want to use a custom element (Web Component) in toDOM()
within a plugin. To get this to work I need to pass properties into the custom element.
From what I can see and have tried, you can only specify attributes in the toDOM() DOMOutputSpec.
For example this is what I need to do in toDOM()
-
['clibu-btn', { '.props': { custom element props... } ]
I am using Lit-element for the Web Components. LE templates are used for this, however I wasn’t able to get them to work in toDOM()
.
I have come up with a hacky work-around, but would prefer a cleaner solution.