fix(web): standalone .spl pages render SPL source as Markdown prose (no code block, no h1) #77

Open
opened 2026-07-04 10:59:58 +00:00 by anuna-02 · 0 comments
anuna-02 commented 2026-07-04 10:59:58 +00:00 (Migrated from codeberg.org)

Summary

Standalone .spl pages are rendered by running the raw SPL source through the Markdown renderer, producing flowing prose paragraphs: ; comments and s-expressions get merged into the same paragraph, all code structure (indentation, one form per line) is lost, and the page has no h1 title.

Found during UAT of v0.9.3 (zetl serve on the bundled demo-vault).

Reproduction

  1. cd demo-vault && zetl serve --port 3777
  2. Open http://localhost:3777/theories/caching/ (source: theories/caching.spl).

Actual

  • Content renders as justified prose paragraphs, e.g. the comment and the following forms fuse into one line: ; Cache is mtime-based (from architecture/Cache.md) (given mtime-based-cache) (given incremental-rebuild).
  • No <pre>/code block anywhere on the page (main pre → none).
  • No h1 (main h1 → null), unlike .md pages which render their title heading.
  • Long atoms (blake3 hashes) wrap mid-token as prose.

Since Markdown interprets the source, SPL files containing #, ---, *, [[...]] etc. at line starts will silently turn into headings/rules/lists.

Expected

Either render .spl source as a preformatted code block (with the existing line anchors kept — those work today and search deep-links rely on them), or as a deliberate structured SPL view. Also emit the page title h1 like .md pages get.

Environment

zetl 0.9.3, zetl serve, demo-vault, Chromium 140.

## Summary Standalone `.spl` pages are rendered by running the raw SPL source through the Markdown renderer, producing flowing prose paragraphs: `;` comments and s-expressions get merged into the same paragraph, all code structure (indentation, one form per line) is lost, and the page has no `h1` title. Found during UAT of v0.9.3 (`zetl serve` on the bundled demo-vault). ## Reproduction 1. `cd demo-vault && zetl serve --port 3777` 2. Open `http://localhost:3777/theories/caching/` (source: `theories/caching.spl`). ## Actual - Content renders as justified prose paragraphs, e.g. the comment and the following forms fuse into one line: `; Cache is mtime-based (from architecture/Cache.md) (given mtime-based-cache) (given incremental-rebuild)`. - No `<pre>`/code block anywhere on the page (`main pre` → none). - No `h1` (`main h1` → null), unlike `.md` pages which render their title heading. - Long atoms (blake3 hashes) wrap mid-token as prose. Since Markdown interprets the source, SPL files containing `#`, `---`, `*`, `[[...]]` etc. at line starts will silently turn into headings/rules/lists. ## Expected Either render `.spl` source as a preformatted code block (with the existing line anchors kept — those work today and search deep-links rely on them), or as a deliberate structured SPL view. Also emit the page title `h1` like `.md` pages get. ## Environment zetl 0.9.3, `zetl serve`, demo-vault, Chromium 140.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
anuna-research/zetl#77
No description provided.