Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class MyCustomElement extends HTMLElement {
- constructor() {
- super();
- this.foo = "bar";
- }
- doSomething() {
- console.log(this.foo);
- }
- }
- customElements.define("my-custom-element", MyCustomElement);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement