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

Set output type of graph to svg #43

Open
danielbinder opened this issue Jan 29, 2024 · 1 comment
Open

Set output type of graph to svg #43

danielbinder opened this issue Jan 29, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request React Understanding React is required

Comments

@danielbinder
Copy link
Owner

danielbinder commented Jan 29, 2024

We want to enable the downloading of graphs, this can be simply done by setting the output type of graphviz to SVG.
While you're at it, please also correct the graph size (500x250 iirc)
This may destroy some information (e.g. state names on hover), so add the state names to the graph nodes themselves, even when they have a label e.g.
name: label

@danielbinder danielbinder added enhancement New feature or request React Understanding React is required labels Jan 29, 2024
@csteidl csteidl self-assigned this Jan 30, 2024
@danielbinder
Copy link
Owner Author

Maybe this can be done by replacing the graphviz-react dependency with d3-graphviz.
It depends on it anyways, but the former does not seem to be maintained actively.
Both seem to be usable in the same way - see: d3-graphviz README

d3.graphviz("#graph").renderDot('digraph {a -> b}');

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

No branches or pull requests

2 participants