Closed stanhu closed 6 years ago
With mermaid 7.1.2 on npm (https://www.npmjs.com/package/mermaid), adding the startOnLoad as mentioned in https://github.com/knsv/mermaid/issues/291#issuecomment-287673609 did not make that issue away for me:
startOnLoad
var config = { startOnLoad: false }; mermaid.initialize(config);
After testing https://github.com/mermaidjs/mermaid-live-editor and setting a breakpoint in https://github.com/knsv/mermaid/blob/6cd5ffe637d88525b93417bf3954e9c0e5a4deb8/src/mermaid.js#L118-L124, I saw that startOnLoad was not being set properly.
Instead, I had to do this:
mermaid.initialize({ mermaid: { startOnLoad: false } });
Is there a documentation error here?
Yes, the documentation is pretty dated.
But I just tested, both code work.
Could you please test the latest mermaid code? Thanks
With mermaid 7.1.2 on npm (https://www.npmjs.com/package/mermaid), adding the
startOnLoad
as mentioned in https://github.com/knsv/mermaid/issues/291#issuecomment-287673609 did not make that issue away for me:After testing https://github.com/mermaidjs/mermaid-live-editor and setting a breakpoint in https://github.com/knsv/mermaid/blob/6cd5ffe637d88525b93417bf3954e9c0e5a4deb8/src/mermaid.js#L118-L124, I saw that
startOnLoad
was not being set properly.Instead, I had to do this:
Is there a documentation error here?