import { h, mount, activateIslands, createSignal } from "@getforma/core"; import { RouterHeader } from "./router-header"; type ShellProps = { count: number; theme: string; themeNext: string }; function RouterLayout(props: { count: number }) { const [count, setCount] = createSignal(props.count); return (

PERSISTENT LAYOUT ISLAND

Keep something here.

{() => count()}

Change this note and count, then switch pages. The same layout island stays alive; a full document load resets it.

); } function RouterShell(props: ShellProps) { return (
Skip to content

SERVER LAB / NATIVE ROUTER

Two real Rust pages. One persistent layout. Each destination starts with fresh typed server props.

Try the document boundary.

These controls deliberately load a complete document. Ordinary links and request forms also work with JavaScript disabled; the counter buttons require JavaScript. Nothing is saved or shared with another visitor.

); } activateIslands({ RouterLayout }); mount( () => RouterShell({ count: 0, theme: "light", themeNext: "dark" }), "#app", );