Description
When using the info diagram type inside a standalone HTML page with Mermaid initialized via ESM, the diagram either does not render or produces inconsistent output. The behavior differs between info and info showInfo, and neither produces clear visible results in the page.
Steps to reproduce
- Create an HTML file with the following content:
<!doctype html>
<title>Mermaid Info Diagram Test</title>
Info diagram demos
<pre class="mermaid">
info
</pre>
<hr />
<pre class="mermaid">
info showInfo
</pre>
<script type="module">
import mermaid from './mermaid.esm.mjs';
mermaid.initialize({
theme: 'forest',
logLevel: 3,
securityLevel: 'loose',
});
</script>
2. Serve the file: http://localhost:9000/info.html
3. Open in browser
4. Observe the rendered output
Screenshots
Code Sample
Setup
- Mermaid version: 11.13.0
- Browser: Chrome
Suggested Solutions
- Clarify Documentation
Define expected output of info diagrams
Document differences between info and info showInfo
- Rendering Feedback
Show warning if diagram produces no visible output
- Consistency
Ensure both variants behave predictably across environments
- Initialization Handling
Optionally auto-render or warn if mermaid.run() is missing
Additional Context
This affects debugging and developer experience, especially when testing Mermaid setup or trying to introspect configuration using info diagrams.
Description
When using the info diagram type inside a standalone HTML page with Mermaid initialized via ESM, the diagram either does not render or produces inconsistent output. The behavior differs between info and info showInfo, and neither produces clear visible results in the page.
Steps to reproduce
- Create an HTML file with the following content:
<title>Mermaid Info Diagram Test</title><!doctype html>
Info diagram demos
Screenshots
Code Sample
Setup
Suggested Solutions
Define expected output of info diagrams
Document differences between info and info showInfo
Show warning if diagram produces no visible output
Ensure both variants behave predictably across environments
Optionally auto-render or warn if mermaid.run() is missing
Additional Context
This affects debugging and developer experience, especially when testing Mermaid setup or trying to introspect configuration using info diagrams.