-
Notifications
You must be signed in to change notification settings - Fork 36
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
Render Mermaid diagrams from an included .mermaid-file #448
Comments
In the I'm running the site generator using docker on windows. |
This scenario is indeed currently not supported, see https://github.com/avisi-cloud/structurizr-site-generatr/blob/main/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/ToHtml.kt#L84 Since you are familiar with the topic and setup for this, any chance your could create a PR for this? |
I did some research into this topic in order to create a PR, but I fail to see a path forward. The problem I see is that there is a separation between the moment where the .adoc-files are being read and where the asciidocToHtml is being done. Reading the files is being done as part of the Structurizr DSL DocsParser The AsciiDoctor Options does not support setting a different basePath. A possible solution could be found in a custom implementation of the DocumentationImporter and adjust the DSL to trigger the DocsParser to use that one. The custom implementation might be given the responsibility to preprocess the content, resolve the includes and inline the partials into the content of the documentation. This would be aligned with the statement in the AsciiDoc documentation about include being a preprocessor directive |
Thanks for the assessment, yeah, looks like a non-trivial feature to implement correctly. Unfortunately we don't use AsciiDoc internally, so I would prefer if this is added by someone who is actually using this feature and knows how to use this in real life. The initial support for AsciiDoc was also a contribution. Sorry. |
User store
In order to being able to reuse diagrams and keep code isolated
As a site developer
I want to be able to include mermaid diagrams from source-files
If I want o render a mermaid diagram in the generated site the diagram as text currently has to be inside the
Current
Wanted
First attempt
References
The text was updated successfully, but these errors were encountered: