For the complete documentation index, see llms.txt. This page is also available as Markdown.

Mermaid blocks

Add a Mermaid block to create diagrams in GitBook using Mermaid syntax

Mermaid blocks let you create diagrams using the Mermaid syntax.

Use them when you want to show flows, sequences, states, or relationships in a format that's easy to update.

Add a Mermaid block

  1. Place your cursor on an empty line and type /.

  2. Click Mermaid in the insert menu.

  3. Enter or paste your Mermaid syntax. GitBook renders the diagram automatically.

You can also click the + to the left of any line in the editor and click Mermaid.

Example

Representation in Markdown

```mermaid
flowchart TD
    A[Open the insert palette] --> B[Select Mermaid]
    B --> C[Add Mermaid syntax]
    C --> D[GitBook renders the diagram]
```

GitBook renders code blocks with the mermaid language identifier as native Mermaid blocks.

Last updated

Was this helpful?

Powered by GitBook