I'm using Mermaid in markdown. I can't figure out how to connect subgraphs.
Given the program below, I need to be able to connect one and two with an arrow.
- ```mermaid
graph LR;
subgraph one
main---MainMenu
MainMenu((MainMenu))---Game
Game---Level
Game---Player
end
subgraph two
Screen
end
one-->two
```
Just FYI, Webstorm Markdown Settings has a one-click "Install" option for Mermaid and also for PlantUML support (Settings => Markdown). After installing it, the Markdown editor shows the rendered diagram in the preview tab (IDEA Markdown editor has a split view of left: Markdown source, right: rendered view).
About Mermaid. Mermaid lets you create diagrams and visualizations using text and code. It is a JavaScript based diagramming and charting tool that renders Markdown-inspired text definitions to create and modify diagrams dynamically. If you are familiar with Markdown you should have no problem learning Mermaid's Syntax ...
The beta now allows you to connect subgraphs:
flowchart TB
c1-->a2
subgraph one
a1-->a2
end
subgraph two
b1-->b2
end
subgraph three
c1-->c2
end
one --> two
three --> two
two --> c2
https://mermaid-js.github.io/mermaid/#/flowchart?id=beta-flowcharts
As far as I know, it's only possible to connect nodes, so you could do:
main-->Screen
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With