Skip to content

Instantly share code, notes, and snippets.

@librasteve
Created January 7, 2026 16:52
Show Gist options
  • Select an option

  • Save librasteve/a81f38f1ced57744e434c13e3571fe2f to your computer and use it in GitHub Desktop.

Select an option

Save librasteve/a81f38f1ced57744e434c13e3571fe2f to your computer and use it in GitHub Desktop.
Air Lit Thoughts
import {html, css, LitElement} from 'lit';
import {customElement, property} from 'lit/decorators.js';
@customElement('simple-greeting')
export class SimpleGreeting extends LitElement {
static styles = css`p { color: blue }`;
@property()
name = 'Somebody';
render() {
return html`<p>Hello, ${this.name}!</p>`;
}
}
#then consume
<!DOCTYPE html>
<head>
<script type="module" src="./simple-greeting.js"></script>
</head>
<body>
<simple-greeting name="World"></simple-greeting>
</body>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment