mjbvz / vscode-markdown-mermaid

Adds Mermaid diagram and flowchart support to VS Code's builtin markdown preview
https://marketplace.visualstudio.com/items?itemName=bierner.markdown-mermaid
MIT License
630 stars 112 forks source link

ELK renderer for Flowcharts is not working #223

Closed Kumar-Saurabh-21co closed 5 months ago

Kumar-Saurabh-21co commented 8 months ago

Mermaid provides an alternative renderer for flowcharts but this is not working with the plugin in vscode. %%{init: {"flowchart": {"defaultRenderer": "elk"}} }%%

The difference with the default dagre renderer is a more orthogonal connectors.

mjbvz commented 7 months ago

Can you please share a complete code example that demonstrates the problem

Kumar-Saurabh-21co commented 7 months ago

Yes sure.

So here is the example from Mermaid Live Editor which displays the effects of elk renderer. This also has the code snippet you can use to test. Mermaid Live Editor Example

And here is the error I get with the same in vs code.

image

And here is the same code only with the renderer as dagre instead of elk

image
mjbvz commented 7 months ago

@Kumar-Saurabh-21co Are you sure you're on the latest extension release. Seems to work fine for me with 1.21

Image

Kumar-Saurabh-21co commented 5 months ago

Hey @mjbvz Yes it works fine in the current version, I was in an older version. Thanks !

Alexandre-SCHOEPP commented 3 months ago

Hi !

I have the same issue in 1.22.0 : My error message is Cannot read properties of null (reading 're'). (At no point do I have a 're' element)

mjbvz commented 3 months ago

@Alexandre-SCHOEPP Please open a new issue with an example chart