Skip to content

Instantly share code, notes, and snippets.

@malteneuss
Last active December 27, 2022 13:54
Show Gist options
  • Save malteneuss/e5d84a9573983a31e3f17a56824715d3 to your computer and use it in GitHub Desktop.
Save malteneuss/e5d84a9573983a31e3f17a56824715d3 to your computer and use it in GitHub Desktop.
How to create rapid programming slides in Markdown with support for PlantUML, Math and two column layout using Pandoc.
pandoc --to revealjs --filter pandoc-plantuml --standalone slides.md --output out.html --katex
# Needs the "pandoc-plantuml" filter installed.
# Uses "katex" for rendering math in html
# (fastest and works reliably for Latex syntax,
# "Mathjax" has support for Asciimath syntax but this syntax seems dead and has bad alignment support,
# "MathML" converter doesn't work for many Latex symbols).
#
title author date plantuml-format theme
Some slides
Some Author
March 23, 2022
svg
league

View this slide raw

Github doesn't render this file correctly

Math

$$ \begin{aligned} \dot{x} & = \sigma(y-x) \\ \dot{y} & = \rho x - y - xz \\ \dot{z} & = -\beta z + xy \end{aligned} $$

$$ J(\theta_0,\theta_1) = \sum_{i=0} $$

PlantUML diagrams

Alice -> Bob: Authentication Request
Bob --> Alice: Authentication Response

Alice -> Bob: Another authentication Request
Alice <-- Bob: another authentication Response

Two columns on slide

:::::::::::::: {.columns} ::: {.column width="50%"}

Title left:

  • One
  • Two

::: ::: {.column width="50%"}

Title right

  • One

::: ::::::::::::::

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment