The Post Is the Slide Deck
colophon now derives a themed slide deck from any post: headings become slides, prose becomes presenter notes, and one line of frontmatter turns it on.
This one is a bit of an experiment. A blog post and a short talk are often the same material, just delivered differently, and people take things in differently too: some will read a post, some would rather sit through a handful of slides. I wanted to see whether one document could be pulled into more than one medium without any significant rewriting. colophon can now do exactly that: a post projects itself into a themed deck, published at /<slug>/slides/ and linked from its Downloads box, with the deck derived from the post rather than maintained beside it. This post is one: open the Slides link and present it.
One document, more than one medium
- The same material, read or presented
- No second copy to keep in sync
- The deck updates when the post does
Turn it on
# colophon.yaml: the site default (off, here)
slides:
enabled: false
# any post: opt in, in the frontmatter
slides: true
What becomes what
flowchart LR P["The post"] --> S["Headings: slides"] P --> N["Prose: presenter notes"] P --> B["Code, images, tables, maths, diagrams: on the slide"]
- Headings split the deck into slides
- Paragraphs drop into the presenter notes
- Everything else stays on the slide: code, images, tables, maths, diagrams, callouts, pull-quotes
Where the breaks go
slides:
enabled: true
split: [h2] # h2 opens a slide; h3 and deeper fold into bullets
- Heading levels:
h1throughh6 - Structural:
hr,splitslide - Block kinds:
image,table,code,math,diagram,audio,video text:<match>: break before a block whose text starts with the match
Three inline markers
<splitslide>forces a break mid-section<slide>…</slide>makes one verbatim slide<noslide>…</noslide>keeps content in the post but out of the deck
Sometimes a slide should be a single line and nothing else. <slide> gives you exactly that, verbatim.
Present it, or read it
- ← / → or swipe to move
- P presenter notes, F fullscreen
- Enter plays the slide's media, Esc closes the deck
On in preview, off in prod
environments:
- name: preview
slides: { enabled: true } # decks on while I'm drafting
- name: production
# inherits the site default (off)
Write the talk once. Let the deck be a view of it, not a second copy.