I’m happy to report that you no longer need JavaScript to see rendered KaTeX expressions and Mermaid diagrams in my blog posts! I wrote a script aftermath that post-processes my blog posts to compile the following to SVGs at build-time:
- KaTeX expressions (using the same settings as the auto-render extension that runs in the browser)
- Mermaid diagrams (using the same settings as Mermaid in the browser)
- D2 diagrams
Check out the aftermath README for more details!
Example Mermaid diagram:
Example KaTeX:
Example D2: