From a06b4d73979b233c845235148b9695ef926cc0ff Mon Sep 17 00:00:00 2001 From: Simon Lecoq <22963968+lowlighter@users.noreply.github.com> Date: Mon, 28 Oct 2024 02:43:06 -0400 Subject: [PATCH] doc: add demo and improve examples --- @mizu/render/static/static.ts | 3 +- www/html/index.html | 2 +- www/html/mizu/api.html | 10 +- www/html/mizu/demo.html | 183 +++++++----- .../browsers/{client2.html => esm.html} | 1 + .../browsers/{client.html => iife.html} | 1 + www/html/mizu/examples/bun/server.ts | 12 - www/html/mizu/examples/deno/ssg.ts | 15 + .../mizu/examples/deno/{server.ts => ssr.ts} | 7 +- www/html/mizu/examples/deno/static.ts | 0 www/html/mizu/features.html | 14 +- www/html/mizu/usage.html | 8 + www/static/styles.css | 266 +++++++++++++++--- 13 files changed, 382 insertions(+), 140 deletions(-) rename www/html/mizu/examples/browsers/{client2.html => esm.html} (94%) rename www/html/mizu/examples/browsers/{client.html => iife.html} (92%) delete mode 100644 www/html/mizu/examples/bun/server.ts create mode 100644 www/html/mizu/examples/deno/ssg.ts rename www/html/mizu/examples/deno/{server.ts => ssr.ts} (58%) delete mode 100644 www/html/mizu/examples/deno/static.ts diff --git a/@mizu/render/static/static.ts b/@mizu/render/static/static.ts index 5ed6065..17c3186 100644 --- a/@mizu/render/static/static.ts +++ b/@mizu/render/static/static.ts @@ -123,9 +123,8 @@ export class Static extends Server { await write(path, await this.#render(encoder.encode(source as string), options.render)) log.with({ path }).ok() } - - log.ok("done!") } + log.ok("done!") } /** Used by {@linkcode Static#generate()} to render content. */ diff --git a/www/html/index.html b/www/html/index.html index 1686887..a7d9ac5 100644 --- a/www/html/index.html +++ b/www/html/index.html @@ -21,7 +21,7 @@
-
+