Mermaid for
Class diagrams
Design object models, define relationships, and document your architecture in a format that lives next to your code.
A class diagram is a UML structural diagram that shows the classes in a system, their attributes and methods, and the relationships between them. The Object Management Group adopted UML (Unified Modeling Language) as a standard in 1997, and the class diagram is one of its most widely used diagrams.
Class diagrams are used for upfront design and for documenting existing codebases. In Mermaid, you write them as text with classDiagram. Mermaid supports inheritance, composition, aggregation, association, dependency, and realization; multiplicity labels such as 1 and 0..*; generics; visibility markers; annotations such as <<interface>>; and namespaces.
One shared canvas for mapping ideas, collaborating live, and keeping teams on the same page, literally.
Common questions about building class diagrams in Mermaid.