Comment by thangalin
11 hours ago
Any idea when Mermaid diagrams will render outside of web browsers?
https://github.com/mermaid-js/mermaid/issues/2485
<rant> Aside, I'm the author of KeenWrite (https://keenwrite.com/), a Markdown text editor that allows embedding diagrams using the triple-backtick syntax. Here's a GraphViz example:
``` diagram-graphviz
digraph {
rankdir="LR";
a -> b -> c;
}
```
KeenWrite parses the `diagram-` prefix then passes the word `graphviz` to Kroki (https://kroki.io/), which has an API for rendering a variety of ASCII diagrams, including Mermaid. Meaning, if Kroki adds a new diagram type, KeenWrite gets it for free (without modification).
In Markdown, formatting a source code snippet entails using the standard syntax for code blocks:
``` graphviz
digraph {
rankdir="LR"
a -> b -> c;
}
```
GitHub created a de facto standard for Mermaid diagrams that breaks the convention of having triple-backticks followed by a language identifier to show the source code for that language in a monospace font. This was an unfortunate decision. </rant>