xmpp.chapril.org-conversejs/src/shared/components/element.js

24 lines
492 B
JavaScript
Raw Normal View History

import { LitElement } from 'lit';
import { Events } from '@converse/skeletor/src/events.js';
export class CustomElement extends LitElement {
createRenderRoot () {
// Render without the shadow DOM
return this;
}
connectedCallback () {
super.connectedCallback();
this.initialize?.();
}
disconnectedCallback () {
super.disconnectedCallback();
this.stopListening();
}
}
Object.assign(CustomElement.prototype, Events);