{"analyzedAt":"2022-12-12T22:22:49.992Z","collected":{"metadata":{"name":"graphviz-builder","scope":"unscoped","version":"0.1.1","description":"Generates the source graph script for Graphviz.","keywords":["graphviz","graph","builder","dot"],"date":"2022-12-11T20:11:27.180Z","author":{"name":"Ferdinand Prantl","email":"prantlf@gmail.com","url":"http://prantlf.tk/","username":"prantlf"},"publisher":{"username":"prantlf","email":"prantlf@gmail.com"},"maintainers":[{"username":"prantlf","email":"prantlf@gmail.com"}],"contributors":[{"name":"Gregoire Lejeune","url":"http://algorithmique.net"},{"name":"Mathieu Ravaux","url":"http://mathieuravaux.com"}],"repository":{"type":"git","url":"git+https://github.com/prantlf/graphviz-builder.git"},"links":{"npm":"https://www.npmjs.com/package/graphviz-builder","homepage":"https://github.com/prantlf/graphviz-builder#readme","repository":"https://github.com/prantlf/graphviz-builder","bugs":"https://github.com/prantlf/graphviz-builder/issues"},"license":"MIT","devDependencies":{"@rollup/plugin-commonjs":"23.0.4","@semantic-release/changelog":"6.0.2","@semantic-release/git":"10.0.1","all-contributors-cli":"6.24.0","c8":"7.12.0","denolint":"2.0.5","jsdoc-to-markdown":"8.0.0","rollup":"3.7.3","rollup-plugin-cleanup":"3.2.1","rollup-plugin-swc-minify":"1.0.5","typescript":"4.9.4"},"releases":[{"from":"2022-11-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":2},{"from":"2022-09-13T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":2},{"from":"2022-06-15T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":2},{"from":"2021-12-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":2},{"from":"2020-12-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":2}],"hasTestScript":true,"hasSelectiveFiles":true,"readme":"# GraphViz Source Script Builder\n\n[![npm](https://img.shields.io/npm/v/graphviz-builder)](https://www.npmjs.com/package/graphviz-builder#top)\n[![codecov](https://codecov.io/gh/prantlf/graphviz-builder/branch/master/graph/badge.svg)](https://codecov.io/gh/prantlf/graphviz-builder)\n![Dependency status](https://img.shields.io/librariesio/release/npm/graphviz-builder)\n[![All Contributors](https://img.shields.io/badge/all_contributors-10-orange.svg?style=flat-square)](#contributors)\n\nGenerates the source graph script as input for [Graphviz] (`dot`), which in turn can generate the graph image.\n\nThis project originated as a fork of [node-graphviz] to offer an easy integration to web browsers and JavaScript and TypeScript environments like [Node.js] and [Deno]. Features:\n\n* UMD build output for web browsers and ESM build output for environments supporting ES6 modules.\n* TypeScript type declarations (typings).\n* No dependencies, including [Node.js] bult-in modules.\n* [Faster](perf/README.md) implementation of attributes using `Map`.\n* [API] compatibility with [node-graphviz], except for the removed graph image generation.\n\nRelated tools:\n\n* [graphviz-cli] - command-line tool for generating graph images from the source scripts\n* [graphviz-webcomponent] - WebComponent for web browsers to display graph images from the source scripts in HTML pages on-the-fly\n\n## Synopsis\n\n```js\nvar graphvizBuilder = require('graphviz-builder');\n\n// Create digraph G\nvar g = graphvizBuilder.digraph(\"G\");\n\n// Add node (ID: Hello)\nvar n1 = g.addNode( \"Hello\", {\"color\" : \"blue\"} );\nn1.set( \"style\", \"filled\" );\n\n// Add node (ID: World)\ng.addNode( \"World\" );\n\n// Add edge between the two nodes\nvar e = g.addEdge( n1, \"World\" );\ne.set( \"color\", \"red\" );\n\n// Print the dot script\nconsole.log( g.to_dot() );\n```\n\n## Installation\n\nMake sure that you have installed [Node.js]. Use your favourite package manager ([NPM], [Yarn] or [PNPM]) to add the `graphviz-builder` module to your project. Add `-D` on the command line if you use a bundler:\n\n```\nnpm i graphviz-builder\nyarn add graphviz-builder\npnpm i graphviz-builder\n```\n\nIf you write a plain HTML page, insert the `graphviz-builder` script pointing wither to CDN or to the local filesystem:\n\n```html\n<script src=https://unpkg.com/graphviz-builder@0.1.1/dist/index.min.js></script>\n<script src=node_modules/graphviz-builder/dist/index.min.js></script>\n```\n\n## Usage\n\nIf you write source code for [Node.js] or for a web application bundler, you can refer to the locally installed `graphviz-builder` module:\n\n```js\nimport { digraph } from 'graphviz-builder';\n// Create digraph G\nconst g = digraph('G');\n// Add node (ID: Hello)\nconst n1 = g.addNode('Hello', { color: 'blue' });\nn1.set('style', 'filled');\n// Add node (ID: World)\ng.addNode('World');\n// Add edge between the two nodes\nconst e = g.addEdge(n1, 'World');\ne.set('color', 'red');\n// Print the dot script\nconsole.log(g.to_dot());\n```\n\nIf you write source code for [Deno], refer to the full URL of `graphviz-builder`:\n\n```js\nimport { digraph } from 'https://unpkg.com/graphviz-builder@0.1.1/dist/index.min.mjs';\n// ...the same code from the Node.js example above\n```\n\nIf you write a plain HTML page, insert the `graphviz-builder` script pointing wither to CDN or to the local filesystem. The AMD module name (and the windows global) is `graphvizBuilder`.:\n\n```html\n<script src=https://unpkg.com/graphviz-builder@0.1.1/dist/index.min.js></script>\n<script src=node_modules/graphviz-builder/dist/index.min.js></script>\n<script>\nconst { digraph } = window.graphvizBuilder;\n// ...the same code from the Node.js example above\n</script>\n```\n\nSee the complete [API] description for more information.\n\n## License\n\nCopyright (c) 2020-2022 Ferdinand Prantl\nCopyright (c) 2010-2019 Gregoire Lejeune\n\nLicensed under the MIT license.\n\n## Contributors\n\nThanks goes to these wonderful people ([emoji key](https://github.com/kentcdodds/all-contributors#emoji-key)):\n\n<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->\n<!-- prettier-ignore-start -->\n<!-- markdownlint-disable -->\n<table>\n  <tr>\n    <td align=\"center\"><a href=\"http://lejeun.es\"><img src=\"https://avatars1.githubusercontent.com/u/15168?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Gregoire Lejeune</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=glejeune\" title=\"Code\">💻</a> <a href=\"https://github.com/prantlf/graphviz-builder/commits?author=glejeune\" title=\"Documentation\">📖</a> <a href=\"#example-glejeune\" title=\"Examples\">💡</a></td>\n    <td align=\"center\"><a href=\"https://tinysubversions.com\"><img src=\"https://avatars3.githubusercontent.com/u/266454?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Darius Kazemi</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=dariusk\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"https://github.com/SebastienElet\"><img src=\"https://avatars0.githubusercontent.com/u/541937?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Sébastien ELET</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=SebastienElet\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"https://github.com/papandreou\"><img src=\"https://avatars3.githubusercontent.com/u/373545?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Andreas Lind</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=papandreou\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"http://www.blakmatrix.com\"><img src=\"https://avatars3.githubusercontent.com/u/91209?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Farrin Reid</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=blakmatrix\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"https://pahen.se\"><img src=\"https://avatars3.githubusercontent.com/u/353888?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Patrik Henningsson</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=pahen\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"https://github.com/pooriaazimi\"><img src=\"https://avatars2.githubusercontent.com/u/814637?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Pooria Azimi</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=pooriaazimi\" title=\"Code\">💻</a></td>\n  </tr>\n  <tr>\n    <td align=\"center\"><a href=\"https://twitter.com/BridgeAR\"><img src=\"https://avatars2.githubusercontent.com/u/8822573?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Ruben Bridgewater</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=BridgeAR\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"https://github.com/mathieuravaux\"><img src=\"https://avatars1.githubusercontent.com/u/38495?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Mathieu Ravaux</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=mathieuravaux\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"https://github.com/prantlf\"><img src=\"https://avatars3.githubusercontent.com/u/733193?s=460&v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Ferdinand Prantl</b></sub></a><br /><a href=\"https://github.com/prantlf/graphviz-builder/commits?author=prantlf\" title=\"Code\">💻</a></td>\n  </tr>\n</table>\n\n<!-- markdownlint-enable -->\n<!-- prettier-ignore-end -->\n<!-- ALL-CONTRIBUTORS-LIST:END -->\n\nThis project follows the [all-contributors] specification. Contributions of any kind welcome!\n\n[all-contributors]: https://github.com/kentcdodds/all-contributors#readme\n[Graphviz]: https://graphviz.org/\n[node-graphviz]: http://github.com/glejeune/node-graphviz#readme\n[graphviz-cli]: https://github.com/prantlf/graphviz-cli#readme\n[graphviz-webcomponent]: https://github.com/prantlf/graphviz-webcomponent#readme\n[Node.js]: https://nodejs.org/\n[Deno]: https://deno.land/\n[NPM]: https://docs.npmjs.com/cli/npm\n[Yarn]: https://classic.yarnpkg.com/docs/cli/\n[PNPM]: https://pnpm.js.org/pnpm-cli\n[API]: API.md#classes"},"npm":{"downloads":[{"from":"2022-12-11T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":49},{"from":"2022-12-05T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":357},{"from":"2022-11-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":1172},{"from":"2022-09-13T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":5302},{"from":"2022-06-15T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":6213},{"from":"2021-12-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":7191}],"starsCount":0},"github":{"forkOf":"glejeune/node-graphviz","starsCount":4,"forksCount":0,"subscribersCount":1,"issues":{"count":0,"openCount":0,"distribution":{"3600":0,"10800":0,"32400":0,"97200":0,"291600":0,"874800":0,"2624400":0,"7873200":0,"23619600":0,"70858800":0,"212576400":0},"isDisabled":false},"contributors":[{"username":"glejeune","commitsCount":41},{"username":"prantlf","commitsCount":32},{"username":"rogelio-meza-t","commitsCount":4},{"username":"SebastienElet","commitsCount":2},{"username":"dariusk","commitsCount":2},{"username":"BridgeAR","commitsCount":2},{"username":"daniel347x","commitsCount":2},{"username":"miparnisari","commitsCount":2},{"username":"mathieuravaux","commitsCount":1},{"username":"papandreou","commitsCount":1},{"username":"blakmatrix","commitsCount":1},{"username":"pahen","commitsCount":1},{"username":"pooriaazimi","commitsCount":1},{"username":"joscha","commitsCount":1},{"username":"i404788","commitsCount":1},{"username":"tolotrasam","commitsCount":1},{"username":"semantic-release-bot","commitsCount":1}],"commits":[{"from":"2022-12-05T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":4},{"from":"2022-11-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":4},{"from":"2022-09-13T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":4},{"from":"2022-06-15T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":4},{"from":"2021-12-12T00:00:00.000Z","to":"2022-12-12T00:00:00.000Z","count":8}]},"source":{"files":{"readmeSize":8011,"testsSize":34777,"hasChangelog":true},"linters":["editorconfig"],"coverage":0.99}},"evaluation":{"quality":{"carefulness":0.49999999999999994,"tests":0.7484999999999999,"health":1,"branding":0},"popularity":{"communityInterest":22,"downloadsCount":1767.3333333333333,"downloadsAcceleration":8.545148401826484,"dependentsCount":0},"maintenance":{"releasesFrequency":1,"commitsFrequency":0.7415753424657534,"openIssues":0.7,"issuesDistribution":0.7}},"score":{"final":0.6368943123016035,"detail":{"quality":0.9169246291051697,"popularity":0.05655781322723997,"maintenance":0.9772048255443389}}}