htm + preact + signals single bundle
by Jason Miller
HTML
<script type="module">
import {
html, h, useSignal, render
} from 'https://npm.reversehttp.com/@preact/signals-core,@preact/signals,htm/preact,preact';
function App() {
const count = useSignal(0);
return html`
<button onClick=${() => count.value++}>
${count}
</button>
`;
}
render(h(App), document.body);
</script>