1
0
mirror of https://github.com/jaandrle/deka-dom-el synced 2025-09-10 19:01:57 +02:00

🔤 Better build and improve texting

This commit is contained in:
2025-03-19 13:57:16 +01:00
parent ad255e3e19
commit 7664932041
28 changed files with 203 additions and 208 deletions

View File

@@ -4,11 +4,11 @@ import { el } from "deka-dom-el";
const button = el("button", {
textContent: "Click me",
className: "primary",
disabled: true
disabled: true,
});
// Shorter and more expressive
// than the native approach
// Add to DOM
document.body.append(button);
document.body.append(button);

View File

@@ -6,6 +6,6 @@ import { el } from "deka-dom-el";
document.body.append(
el("div").append(
el("h1", "Title"),
el("p", "Paragraph")
)
el("p", "Paragraph"),
),
);