mermaid-js / mermaid-cli

Command line tool for the Mermaid library
MIT License
2.39k stars 227 forks source link

Custom image output for .md file input #661

Open 2nPlusOne opened 6 months ago

2nPlusOne commented 6 months ago

I've started to use the mermaid cli in a personal project to generate a readme from markdown containing mermaid snippets. I want the output to go to the root of the project, but it gets pretty cluttered when all of the svg images are automatically added there as well. I'd rather the images get dropped into my docs folder.

It'd be nice if we could specify an optional override for the image output location when we're sending a markdown as input. My thinking is that this would also automatically update the relative links for the images in the generated markdown file.

https://github.com/mermaid-js/mermaid-cli/assets/39078738/6a41b840-3cb3-4345-a529-43972501e156

PatDyn commented 4 months ago

I second that. This would be a good addition for complex website layouts.