mirror of
https://github.com/jaandrle/deka-dom-el
synced 2025-07-01 04:12:14 +02:00
✨ Add docs page
This commit is contained in:
14
docs_src/components/examples/helloWorld.js
Normal file
14
docs_src/components/examples/helloWorld.js
Normal file
@ -0,0 +1,14 @@
|
||||
import { el, S } from "../../../index-with-signals.js";
|
||||
const clicks= S(0);
|
||||
document.body.append(
|
||||
el("<>").append(
|
||||
el("p", S(()=>
|
||||
"Hello World "+"🎉".repeat(clicks())
|
||||
)),
|
||||
el("button", {
|
||||
type: "button",
|
||||
onclick: ()=> clicks(clicks()+1),
|
||||
textContent: "Fire"
|
||||
})
|
||||
)
|
||||
);
|
Reference in New Issue
Block a user