2023-11-05 21:49:32 +01:00
|
|
|
|
import { el } from "deka-dom-el";
|
2023-11-10 17:15:59 +01:00
|
|
|
|
import "./global.css.js";
|
|
|
|
|
import { example } from "./components/example.html.js";
|
2023-11-06 20:20:32 +01:00
|
|
|
|
|
|
|
|
|
import { header } from "./layout/head.html.js";
|
2023-11-10 17:15:59 +01:00
|
|
|
|
import { prevNext } from "./components/prevNext.html.js";
|
2023-11-07 15:10:55 +01:00
|
|
|
|
/** @param {import("./types.d.ts").PageAttrs} attrs */
|
2023-11-10 17:15:59 +01:00
|
|
|
|
export function page({ pkg, info }){
|
2023-11-07 15:10:55 +01:00
|
|
|
|
const page_id= info.id;
|
2023-11-06 14:04:27 +01:00
|
|
|
|
return el().append(
|
2023-11-10 17:15:59 +01:00
|
|
|
|
el(header, { info, pkg }),
|
2023-11-07 15:10:55 +01:00
|
|
|
|
el("main").append(
|
2023-11-10 17:15:59 +01:00
|
|
|
|
el("p", "The library tries to provide pure JavaScript tool(s) to create reactive interfaces."),
|
2023-11-17 16:15:26 +01:00
|
|
|
|
el("p").append(
|
|
|
|
|
"We start with creating and modifying a static elemnets and end up with UI templates.",
|
|
|
|
|
" ",
|
|
|
|
|
el("i").append(
|
|
|
|
|
"From ", el("code", "document.createElement"), " to ", el("code", "el"), "."
|
|
|
|
|
),
|
|
|
|
|
" ",
|
|
|
|
|
"Then we go through the native events system and the way to include it declaratively in UI templates.",
|
|
|
|
|
" ",
|
|
|
|
|
el("i").append(
|
|
|
|
|
"From ", el("code", "element.addEventListener"), " to ", el("code", "on"), "."
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
el("p").append(
|
|
|
|
|
"Next step is providing interactivity not only for our UI templates.",
|
|
|
|
|
" ",
|
|
|
|
|
"We introduce signals (", el("code", "S"), ") and how them incorporate to UI templates.",
|
|
|
|
|
),
|
|
|
|
|
el("p").append(
|
|
|
|
|
"Now we will clarify how the signals are incorporated into our templates with regard ",
|
|
|
|
|
"to application performance. This is not the only reason the library uses ",
|
|
|
|
|
el("code", "scope"), "s. We will look at how they work in components represented ",
|
|
|
|
|
"in JavaScript by functions."
|
|
|
|
|
),
|
2023-11-10 17:15:59 +01:00
|
|
|
|
el(example, { src: new URL("./components/examples/helloWorld.js", import.meta.url), page_id }),
|
|
|
|
|
el(prevNext, info)
|
2023-11-07 15:10:55 +01:00
|
|
|
|
)
|
2023-09-26 16:02:10 +02:00
|
|
|
|
);
|
|
|
|
|
}
|