#mdbook #plantuml #markdown #commonmark

app mdbook-puml

A simple mdbook preprocessor for rendering inline PlantUML code blocks into inline SVG

2 releases

0.1.1 May 16, 2020
0.1.0 May 16, 2020

#7 in #plantuml


132 lines


This is a simple mdbook preprocessor designed to replace code blocks that look like:

Bob -> Alice : Hello!

with an inline SVG rendered using PlantUML:


I created this preprocessor because mdbook-plantuml wasn't working for me—specifically, mdbook-plantuml is currently incompatible with mdbook watch and mbbook serve because it triggers a rebuild loop.

This crate is quite simple and non-customizable at this point as it does all that I need it to for my own purposes. Feel free to fork and/or PR away though, and I'll be happy to include changes.


To install mdbook-puml, use cargo:

cargo install mdbook-puml

Then add the following to book.toml:


Finally, to insert a PlantUML diagram somewhere, just use a fenced code block with the language set to plantuml:

Bob -> Alice : Hello!


~319K SLoC