Created
March 13, 2019 14:13
-
-
Save vsavkin/10a1e9534aca2caa10391a5da35c7cc6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export class GreetingElement extends HTMLElement { | |
public static observedAttributes = ['title']; | |
attributeChangedCallback() { | |
this.innerHTML = `<h1>Welcome to ${this.title}!</h1>`; | |
} | |
} | |
customElements.define('happynrwl-greeting', GreetingElement); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment