File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -62,6 +62,26 @@ Would end up like this:
62
62
```
63
63
An id is also added to mermaid tags without id.
64
64
65
+ ## Calling ` mermaid.init `
66
+ By default, ` mermaid.init ` will be called when the document is ready, finding all elements with
67
+ ` class="mermaid" ` . If you are adding content after mermaid is loaded, or otherwise need
68
+ finer-grained control of this behavior, you can call ` init ` yourself with:
69
+ - a configuration object
70
+ - some nodes, as
71
+ - a node
72
+ - an a array-like of nodes
73
+ - or W3C selector that will find your nodes
74
+
75
+ Example:
76
+ ```
77
+ mermaid.init({noteMargin: 10}, ".someOtherClass");
78
+ ```
79
+ Or with no config object, and a jQuery selection:
80
+ ```
81
+ mermaid.init(undefined, $("#someId .yetAnotherClass"));
82
+ ```
83
+
84
+
65
85
# Example of marked renderer
66
86
67
87
This is the renderer used for transforming the documentation from markdown to html with mermaid diagrams in the html.
You can’t perform that action at this time.
0 commit comments