Cheat sheet

mermaid play ground

Examples

Flowchart

#

flowchart LR A[Hard] -->|Text| B(Round) B --> C{Decision} C -->|One| D[Result 1] C -->|Two| E[Result 2]

Sequence diagram

sequenceDiagram Alice->>John: Hello John, how are you? loop HealthCheck John->>John: Fight against hypochondria end Note right of John: Rational thoughts! John-->>Alice: Great! John->>Bob: How about you? Bob-->>John: Jolly good!

Gant Chart

gantt section Section Completed :done, des1, 2014-01-06,2014-01-08 Active :active, des2, 2014-01-07, 3d Parallel 1 : des3, after des1, 1d Parallel 2 : des4, after des1, 1d Parallel 3 : des5, after des3, 1d Parallel 4 : des6, after des4, 1d

Class Diagram

classDiagram Class01 <|-- AveryLongClass : Cool <<Interface>> Class01 Class09 --> C2 : Where am I? Class09 --* C3 Class09 --|> Class07 Class07 : equals() Class07 : Object[] elementData Class01 : size() Class01 : int chimp Class01 : int gorilla class Class10 { <<service>> int id size() }

State diagram

stateDiagram-v2 [*] --> Still Still --> [*] Still --> Moving Moving --> Still Moving --> Crash Crash --> [*]

Pie chart

pie "Dogs" : 386 "Cats" : 85.9 "Rats" : 15

Bar chart

gantt title Git Issues - days since last update dateFormat X axisFormat %s section Issue19062 71 : 0, 71 section Issue19401 36 : 0, 36 section Issue193 34 : 0, 34 section Issue7441 9 : 0, 9 section Issue1300 5 : 0, 5

User Journey diagram

journey title My working day section Go to work Make tea: 5: Me Go upstairs: 3: Me Do work: 1: Me, Cat section Go home Go downstairs: 5: Me Sit down: 3: Me

C4 diagram

C4Context title System Context diagram for Internet Banking System Person(customerA, "Banking Customer A", "A customer of the bank, with personal bank accounts.") Person(customerB, "Banking Customer B") Person_Ext(customerC, "Banking Customer C") System(SystemAA, "Internet Banking System", "Allows customers to view information about their bank accounts, and make payments.") Person(customerD, "Banking Customer D", "A customer of the bank, <br/> with personal bank accounts.") Enterprise_Boundary(b1, "BankBoundary") { SystemDb_Ext(SystemE, "Mainframe Banking System", "Stores all of the core banking information about customers, accounts, transactions, etc.") System_Boundary(b2, "BankBoundary2") { System(SystemA, "Banking System A") System(SystemB, "Banking System B", "A system of the bank, with personal bank accounts.") } System_Ext(SystemC, "E-mail system", "The internal Microsoft Exchange e-mail system.") SystemDb(SystemD, "Banking System D Database", "A system of the bank, with personal bank accounts.") Boundary(b3, "BankBoundary3", "boundary") { SystemQueue(SystemF, "Banking System F Queue", "A system of the bank, with personal bank accounts.") SystemQueue_Ext(SystemG, "Banking System G Queue", "A system of the bank, with personal bank accounts.") } } BiRel(customerA, SystemAA, "Uses") BiRel(SystemAA, SystemE, "Uses") Rel(SystemAA, SystemC, "Sends e-mails", "SMTP") Rel(SystemC, customerA, "Sends e-mails to")

XY-Chart

xychart-beta title "Marktperformance 2025: Monatliche Trends (Indexierte Werte)" x-axis ["Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez"] y-axis "Performance (Start = 100)" %% Daten basieren auf realen 2025-Trends: %% Silber: Top Performer (+147-149% im Jahr) line [105, 115, 130, 150, 165, 180, 200, 215, 230, 240, 245, 249] %% Gold: Starkes Jahr (+60-65%), Peak im Dezember bei ca. $4.550 line [108, 112, 110, 118, 125, 130, 135, 142, 148, 155, 158, 165] %% S&P 500: Solides Wachstum (+16,4%), Tech-getrieben line [103, 105, 104, 102, 107, 109, 111, 113, 114, 115, 116, 116.4] %% Bitcoin: Volatil, Allzeithoch im Okt (ca. $104k), Korrektur im Dez (ca. $87k) line [111, 105, 83, 75, 91, 92, 103, 102, 98, 115, 92, 97] %% Western Digital (WDC) - Top Aktie, +261% line [100, 105, 120, 145, 160, 180, 210, 230, 250, 280, 310, 361] %% SVS Baker Steel Fund - Top Fonds, +171% line [100, 110, 125, 135, 140, 150, 160, 175, 190, 210, 230, 271] %% Micron Tech (MU) - Zweitbeste Aktie, +178% (basierend auf Jan-Dez Preis) line [100, 105, 118, 130, 145, 160, 180, 200, 220, 260, 300, 320] %% Bitcoin (BTC) - Top Krypto, +16% (moderat im Gesamtbild) line [100, 103, 102, 98, 105, 108, 110, 107, 112, 120, 105, 116] %% WTI Crude Oil (Rohöl) - Verlierer, -19% line [100, 98, 92, 86, 84, 90, 95, 90, 88, 85, 83, 81]

XY-Chart horizontal

xychart-beta horizontal title "Sales Revenue" x-axis [jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec] y-axis "Revenue (in $)" 4000 --> 11000 bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000] line [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]

Block diagram

block-beta columns 5 A B C D:2 E:4 F G:2 H:3