Published
Edited
Apr 27, 2021
Also listed in…
API
Working Libraries
Insert cell
Insert cell
Insert cell
Insert cell
{
class SimpleGreeting extends lit.LitElement {
static get styles() {
return lit.css`p { color: blue }`;
}

static get properties() {
return {
name: {type: String}
}
}

constructor() {
super();
this.name = 'Somebody';
}

render() {
return html`<p>Hello, ${this.name}!</p>`;
}
}

customElements.define('simple-greeting', SimpleGreeting);
}
Insert cell
html`<simple-greeting name="World"></simple-greeting>`
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more