About this project

Mermaid is a JavaScript-based diagramming and charting tool that uses Markdown-inspired text definitions and a renderer to create and modify complex diagrams. Its stated main purpose is to help documentation catch up with development by making diagrams easy to modify as text. The project is open source under the MIT license and is distributed as an npm package. The README lists support for 20 or more diagram types, including Flowchart, Sequence, Class, State, ER, Gantt, Pie, Git Graph, Mindmap, Timeline and Sankey. Diagrams are written as text rather than drawn with drag-and-drop tools, so they can live alongside code and be reviewed through version control. The project provides a live editor at mermaid.live for prototyping, and Mermaid code blocks are natively rendered in Markdown on GitHub. It also offers integrations with other applications and documentation tooling. Customization options include themes, colors, fonts and layout directions. For security, Mermaid includes built-in sanitization and a sandboxed rendering mode in which diagrams are rendered in a sandboxed iframe to prevent JavaScript embedded in user content from executing. The README notes that this mode can block some interactive functionality along with potentially malicious code. The project describes itself as lightweight with no heavy dependencies and maintains an active community with frequent releases. Related projects include a Command Line Interface, the Live Editor and an HTTP Server. The repository README also references official documentation, a getting started guide, CDN availability, tutorials and a contributing guide. Mermaid won the JS Open Source Awards in 2019 in the category of most exciting use of technology.