ELK +esm issue #4449
-
I tried to use elk editor in my project. Unfortunately I keep getting 500 error in the console for this url: https://cdn.jsdelivr.net/npm/[email protected]/lib/elk.bundled.js/+esm I see that Live Editor works fine. Any Idea what needs to be done here? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
How are you using the script? From the docs... <body>
<script type="module">
import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.esm.min.mjs';
mermaid.initialize({ startOnLoad: true });
</script>
</body> |
Beta Was this translation helpful? Give feedback.
-
In .js file: |
Beta Was this translation helpful? Give feedback.
-
OK, I replaced "import mermaid from 'https://cdn.jsdelivr.net/npm/[email protected]/+esm'" Any idea why everything else works with first import except elk diagrams? I still do not think Error 500 should be thrown in that case. Are there any obvious differences between these two approaches? |
Beta Was this translation helpful? Give feedback.
How are you using the script?
From the docs...