register Web Component
fun <X : Element, T : WebComponent<X>> registerWebComponent(localName: String, webComponent: T, vararg observedAttributes: String)
Content copied to clipboard
registers a WebComponent at the browser's registry, so you can use it in fritz2 by custom-Tag or in HTML. So to make a component that can be added by just importing your javascript, call this in main.
Parameters
localName
name of the new custom tag (must contain a '-')
webComponent
instance of a WebComponent
observedAttributes
attributes to be observed, changes will occur on WebComponent.attributeChanges
fun <E : Element, T : WebComponent<E>> registerWebComponent(localName: String, constructor: KClass<T>, vararg observedAttributes: String)
Content copied to clipboard
registers a WebComponent at the browser's registry, so you can use it in fritz2 by custom-Tag or in HTML. So to make a component that can be added by just importing your javascript, call this in main.
Parameters
localName
name of the new custom tag (must contain a '-')
constructor
class describing the component to register implementing WebComponent
observedAttributes
attributes to be observed, changes will occur on WebComponent.attributeChanges