Modules tiles.syn generator.syn renderer.syn config.syn main.syn bundled to one JS file by synth --bundle
Seed code
Loading dungeon…

Source modules — v0.6.0 Result · ? · @throws · refine

tiles.syn
export type Tile tagged union with 7 variants. Glyph, label & passability helpers. 5 @test declarations.
generator.syn
LCG-seeded procedural map generator. Tile probability scales by level. export fn generate and count_tag. 4 @test declarations.
renderer.syn
export fn render_map, render_legend, render_stats. Converts grid to HTML colour spans.
config.syn ✦ v0.6
Parses level:seed codes into DungeonConfig. Three @throws functions chain via ? — precise error messages at the exact field that fails. refine documents invariants. 9 @test declarations.
main.syn
DOM wiring. Imports parse_config from config.syn — matches Result to render the dungeon or display the error inline. Code input auto-syncs to current state.
All dungeon logic written across 4 source files, bundled to a single JS file by synth --bundle.