Skip to content

Untitled object in Mermaid Config Schema ​

txt
https://mermaid.js.org/schemas/config.schema.json#/properties/layered

Options for the layered layout (beta), used with layout: layered.

AbstractExtensibleStatusIdentifiableCustom PropertiesAdditional PropertiesAccess RestrictionsDefined In
Can be instantiatedNoUnknown statusNoForbiddenAllowednoneconfig.schema.json*

layered Type ​

object (Details)

layered Properties ​

PropertyTypeRequiredNullableDefined by
edgeRoutingstringOptionalcannot be nullMermaid Config
lineHopsMergedOptionalcannot be nullMermaid Config

edgeRouting ​

How the layered layout routes edges between nodes.

  • rounded: edges run on tracks between ranks with radius-5 rounded corners (smaller on short segments).
  • curved: each edge runs as smooth curves between ranks.
  • stepped: edges run on tracks between ranks; each turn is softened over at most 12 px.
  • straight: each edge runs as straight lines from point to point.

edgeRouting

edgeRouting Type ​

string

edgeRouting Constraints ​

enum: the value of this property must be equal to one of the following values:

ValueExplanation
"rounded"
"curved"
"stepped"
"straight"

edgeRouting Default Value ​

The default value is:

json
"rounded"

lineHops ​

Renders edge crossings as small arcs ("hops") or visible gaps, so that it is clear which line passes over which where two edges meet, as the elk layout does.

The edge that gives way loses its corner rounding for the segment carrying the hop, which is the trade for a readable crossing. Curved edges (edgeRouting: curved) are skipped rather than rewritten, to avoid corrupting their geometry. Set to false to draw plain crossings.

lineHops

lineHops Type ​

merged type (Details)

one (and only one) of

lineHops Default Value ​

The default value is:

json
true
Opens in mermaid.ai