Published
Edited
Jan 30, 2019
Insert cell
Insert cell
riot = {
const riot = await require('https://unpkg.com/riot@3.13.2/riot+compiler.js')
window.riot = riot
return riot
}
Insert cell
app = html`<app></app>`
Insert cell
appTag = html`
<template>
<app>
<p>{opts.message}, World!</p>
<p ref="timestamp"></p>

<style>
:scope {
color: blue;
}
</style>

<script>
this.on('mount', () => {
this.refs.timestamp.textContent = Date.now()
})
</script>
</app>
</template>
`
Insert cell
{
riot.compile(appTag.innerHTML)
riot.mount('app', { message: 'Hello' })
}
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