普通流程图

各种排列方式: LR, RL, TB, BT

flowchart BT 
a <--> b
a -- this is a text --> c
b -- another text--> d
b -->|another text| e
c -.-> h
c -..-> g

调整流程图的边框和样式

flowchart LR
    id1(Start)-->id2(Stop)
    style id1 fill:#f9f,stroke:#333,stroke-width:4px
    style id2 fill:#bbf,stroke:#f66,stroke-width:2px,color:#fff,stroke-dasharray: 5 5

子流程图和流程图之间的连线

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

流程图示例

flowchart LR
    A[Hard edge]-->|Link text| B(Round edge)
    B--> C{Decision}
    C-->|One| D[Result one]
    C-->|Two| E[Result two]

时序图

sequenceDiagram
    participant Alice
    participant Bob
		participant Cindy
    Alice->>Bob: Hi Bob
    Bob->>Alice: Hi Alice
    Alice->>Cindy: Hi Cindy
sequenceDiagram
    par Alice to Bob
        Alice->>Bob: Go help John
    and Alice to John
        Alice->>John: I want this done today
        par John to Charlie
            John->>Charlie: Can we do this today?
        and John to Diana
            John->>Diana: Can you help us today?
        end
    end

参考文档: https://mermaid-js.github.io