Closed Testare closed 1 year ago
Hi @Testare, this case has to be supported by a macro, there's no way to do it without modifying aquamarine
@Testare this is not exactly the feature you specified above, but this PR #26 is how I'm including the contents of an external file (it can probably be modified for the API you specified if this does not meet your usecase).
#[cfg_attr(doc, aquamarine, path = "./diagram.md")]
Hope this is helpful!
Fixed in #26, huge thanks to @drbh
I think this is a great project. I was trying to use aquamarine so I could have diagrams for some high-level designs in my crate, and given the potential complexity of this I wanted to write this documentation in its own file and add it to the module like so
I've also tried
I've also tried rearranging the order but it seems not to matter.
However, in both cases what happens is that the file is included, and the mermaid code blocks are rendered as regular code blocks instead of diagrams. I'm a relatively new rustacean with no macro writing experience, is there a way to accomplish this?