English | 简体中文
limu is a diagram layout engine in Go. It reads Mermaid and leaves the drawing to your program, which can draw natively with MyGo, as SVG, or in a style of its own.
Most of limu is ported from Pele, the Mermaid renderer made by the Obsidian team. Pele writes SVG. limu stops one step earlier, at the scene, which is the laid-out diagram as data. limu's tests compare its output with Pele's, number for number.
Warning
limu is an early, personal project, and its API may change in any 0.x release.
go get github.com/firede/limusc, err := limu.Layout("flowchart LR\n A[Text] --> B[Scene] --> C{Backend}", nil)
if err != nil {
return err
}
out := svg.Render(sc, nil)limu reads every diagram type Pele draws, from flowcharts and sequence diagrams to
sankey, C4 and wardley diagrams. To draw with MyGo, use the separate module
github.com/firede/limu/limumygo.
limu.firede.com has the documentation, examples of every diagram type, and a playground to try your own diagrams.
- Getting started
- MyGo, SVG and Theming
- API
- Architecture and Compatibility
./scripts/verify.shThis runs go vet, gofmt and the tests of both modules. On Linux, the limumygo
tests need Pango (libpangocairo-1.0-0). docs/design.md explains
how limu is built and how it's checked against Pele, and AGENTS.md has
the rules for changing it.
MIT. See LICENSE, which also includes Pele's license.