Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mermaid Support #243

Open
brophdawg11 opened this issue Apr 1, 2024 · 2 comments
Open

Mermaid Support #243

brophdawg11 opened this issue Apr 1, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@brophdawg11
Copy link
Contributor

It would be awesome to add mermaid support in our markdown files via mermaid code blocks like github has:

https://github.blog/2022-02-14-include-diagrams-markdown-files-mermaid/

Then we could include all sorts of diagrams in our markdown files.

References:

@brophdawg11 brophdawg11 added the enhancement New feature or request label Apr 1, 2024
@kandros
Copy link
Contributor

kandros commented Apr 4, 2024

👋 @brophdawg11
I was able to make it work
image

Turns out rehype-mermaid depends on playwright in order to render the image, do you think this is acceptable or is a blocker to continue?

@brophdawg11
Copy link
Contributor Author

I think folks on twitter were saying mermaid adds pretty significant bundle bloat - can you confirm/deny the change in client-side JS payload when this is added?

If there is a bloat I think we may need to look into lazily loading the mermaid dependencies and rendering the diagrams client side only - although that could introduce a potentially bad CLS if the diagram was above the fold. I wonder if they could be pre-rendered to SVG's on the server somehow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants