<example-element>test</example-element>
class ExampleElement extends HTMLElement {
constructor() {
super();
console.log("Example element added to page.");
}
}
customElements.define("example-element", ExampleElement);
View Compiled
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.