3 ms·
Has Graphviz been re-implemented in JavaScript or compiled to WASM?
by WalterGR 5y ago
Has Graphviz been re-implemented in JavaScript or compiled to WASM?
- jonpalmisc 5y agoThere are definitely some JS libraries for it that exist. I don’t know all the details but I often find myself Googling “graphviz online” and clicking the first link to quickly mock up diagrams. So in short, I’ve used it on the web before.
- lelandbatey 5y agoOther services, such as Gitlab[0], allow you to embed Graphviz & PlantUML into a README just like (and alongside) Mermaid, but the images are rendered server-side. [0] - https://docs.gitlab.com/ee/administration/integration/plantuml.html https://docs.gitlab.com/ee/administration/integration/plantu...
- donatj 5y agoIt's a simple well documented language. Righting a fully functional JS Graphviz parser from scratch would take a couple days at most.
- deleted 5y ago[deleted]
- WalterGR 5y agoThe parser is only the beginning. Table stakes. For example: GraphViz has 8 layout engines. Which of those need to be implemented in JS?
- ygra 5y agoHaving tried to think about how to map Graphviz (language parsing, styles, and layout) onto our graph drawing offering, I'm not sure I can agree here. The dot graph description language itself is fairly simple (-ish). There are a few nasties like the HTML record support, which can be annoying to support, but overall that part isn't so bad. When it comes to laying out the graphs and rendering anything Graphviz has so many unique features that it can be a lot more work.
- schemescape 5y agoYes, several times: http://viz-js.com/ http://viz-js.com/ https://www.npmjs.com/package/@hpcc-js/wasm https://www.npmjs.com/package/@hpcc-js/wasm I even did it myself a few months ago :)