← Back to context

Comment by idoubtit

5 hours ago

Comparing MermaidJS with Kroki is a bit like comparing PDF.js to Adobe Acrobat. I don't think either is better than the other, they're just for different use-cases.

With MermaidJS, converting a diagram inside a web page requires adding a handful of lines to a HTML page. The execution is fast and local.

Kroki is a web-service. To use it in a web page means adding a dependency to an external provider (a free service exists, but asks for fundings). An alternative is self-hosting by running a Kroki container.

A few years ago, I added Mermaid diagrams to a project in a few minutes of work. Had we needed a much more complex tool, maybe I would have gone with Kroki, but not by myself; it would have required a change in the deploying process of the project.

> An alternative is self-hosting by running a Kroki container.

Exactly, which is why KeenWrite has a "Diagram server" setting:

https://i.ibb.co/LXxm33cb/diagram-server.png

> they're just for different use-cases

Sure. A software system could support one plain text diagram format, or support a multitude without tons more effort, architecturally speaking.