mdbook-graphviz
mdbook-graphviz copied to clipboard
Adding additional code->svg tools
I've been working on an mdbook d2 renderer lately and most of the code is exactly the same as the graphviz code. It would be great to share some of the logic / backport the improvements I've made (svg zoom and pan) back to this repo.
I think there are a few ways we could do this:
- Make this a mono repo, rename it to
mdbook-preprocessors
, have a shared cratemdbook-inline-svg-preprocessor
, then have each preprocessor inherit frommdbook-inline-svg-preprocessor
. - Have the same crate structure but in 3 different repos.
- Wrap everything up into 1 executable but still rename the repo.
Right now I'm inclined to go with Option 1. Option 2 seems too tedious to be reasonable. Option 3 seems compelling but I've been calling d2 via their golang library instead of the CLI which (while very powerful) introduces some interesting compilation requirements in osx. I wouldn't want to break graphviz rendering for any consumers outside of osx, especially if it proves challenging to setup the correct install for consumers without golang installs.