This is a collection of packages for working with Graphviz in JavaScript.
To render a graph as an SVG string:
import { dot2svg } from "@viz-js/dot2svg";
const svg = await dot2svg("digraph { a -> b }");Packages:
- viz — WebAssembly build of Graphviz and JavaScript wrapper.
- dot2svg — Simplified interface for the
vizpackage. - lang-dot — CodeMirror language support for the Graphviz DOT language.
- viz is published on NPM as
@viz-js/viz. - dot2svg is published on NPM as
@viz-js/dot2svg. - lang-dot is published on NPM as
@viz-js/lang-dot.