This library provides a TypeScript friendly model of the Graphviz DOT language and functions to execute DOT commands. It also provides a module to manipulate AST as a low-level API.
This library is also used by big names such as Apollo GraphQL and AWS CDK plugins, and has now grown to a 100k+ weekly dl project.
I started this project to use it in the backend of Rediagram framework to generate infrastructure diagrams in React. See also https://news.ycombinator.com/item?id=24685886 .