Render a slide deck

§ 1Purpose

Turn a site into a keyboard-navigated slide deck with the :presentation template and a deck grid.

§ 2Prerequisites

§ 3Flowchart

1. Opt the site into the presentation template2. Lay out the deckgrid3. Add reveals and speaker notes4. Build and present

§ 4Steps

§ 4.11

§ 4.2Opt the site into the presentation template

wcl
site talk {
  default_template = :presentation
  title            = "My talk"
  theme            = :nord
}

Set default_template = :presentation on the site. The whole site renders into a single index.html navigated with the keyboard — ← → move between sections, ↑ ↓ between the slides within one.

§ 4.32

§ 4.4Lay out the deck grid

wcl
site talk {
  default_template = :presentation
  title            = "My talk"
  deck {
    section "Intro" {
      slide title_slide
      slide agenda
    }
    section "Main" { slide topic }
  }
}

Declare a deck block on the site: each section is a column of the 2-D grid and each slide names a page belonging to this site. Each slide must sit on its own line.

§ 4.53

§ 4.6Add reveals and speaker notes

wcl
page topic {
  h2 "Key points"
  fragment { p "Revealed on the first Space" }
  fragment { p "…then this one" }
  notes { p "Reminder: mention the benchmark numbers." }
}

Inside a slide page, a fragment { … } is a step-reveal group (hidden until the presenter advances with Space) and a notes { … } holds speaker notes (hidden in the deck, shown in the overlay toggled with s).

§ 4.74

§ 4.8Build and present

console
$ wcl wdoc build talk.wcl --out out/talk

Render with the ordinary build target (or iterate under wcl wdoc serve). Open out/talk/index.html and drive the deck with the arrow keys.

Verification

out/talk/index.html opens as a deck: arrow keys move between slides, Space reveals fragments, and s toggles the notes overlay.