-
Notifications
You must be signed in to change notification settings - Fork 122
Add mermaid file export functionality #145
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this contribution.
Can you maybe clarify the use case of the plain method?
I don't see the added value, as you typically want to copy from the output to something else anyway..?
I don't like that this copies the content of forum.py
.
One could use from forum import Base
instead.
Or just provide an (additional) CLI mode flag and just add a cli example.
A valid usage would be to save the database to Then we should add it for this export format as well in Lines 231 to 235 in b036a16
|
I need to have ER Diagram as a markdown file in documentation. It is because it can easily rendered in github markdown. The markdown file is easier to do quick changes and preview it instead of an image.
That was my mistake I had fixed it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove code duplication
Use Case wise I would also like to regular refresh the image in ci. No need to embed it into another markdown. Linking is just fine. |
|
I am still quite unsure if @rbange has the same use-case as @Mahad-lab.
is what would be sufficient for @rbange ? Or is the current state of this PR what you would need? As I understand, @Mahad-lab would like to have the mermaid source surrounded by ` (backticks), which would then not be compatible with mermaid cli anymore. Other tools like https://github.com/Mermaid-Chart/vscode-mermaid-preview?tab=readme-ov-file#standalone-mermaid-files support both formats. |
Furthermore it is possible to integrate other mermaid files into rst docs using:
But this is not yet rendered in github/gitlab |
Our main use-case is that our security monitoring can't send data to |
Currently, the Mermaid diagrams are exported into a Markdown file as comments and rendered as images using the mermaid.ink link.
I have now implemented a feature to export the Mermaid diagrams into a Markdown file with the
mode="mermaid_plain"
parameter.