{"analyzedAt":"2022-07-05T06:48:07.057Z","collected":{"metadata":{"name":"@ts-graphviz/react","scope":"ts-graphviz","version":"0.9.1","description":"Graphviz-dot Renderer for React.","keywords":["graphviz","dot","react"],"date":"2021-09-25T08:19:54.514Z","author":{"name":"kamiazya","email":"yuki@kamiazya.tech","username":"kamiazya"},"publisher":{"username":"kamiazya","email":"yuki@kamiazya.tech"},"maintainers":[{"username":"kamiazya","email":"yuki@kamiazya.tech"}],"repository":{"type":"git","url":"git+https://github.com/ts-graphviz/react.git"},"links":{"npm":"https://www.npmjs.com/package/%40ts-graphviz%2Freact","homepage":"https://github.com/ts-graphviz/react#readme","repository":"https://github.com/ts-graphviz/react","bugs":"https://github.com/ts-graphviz/react/issues"},"license":"MIT","dependencies":{"prop-types":"^15.7.2","react-dom":"^17.0.2","react-reconciler":"^0.26.2","ts-graphviz":"^0.16.0"},"devDependencies":{"@testing-library/jest-dom":"^5.12.0","@testing-library/react":"^11.2.7","@testing-library/react-hooks":"^5.1.2","@types/prop-types":"^15.7.3","@types/react":"^17.0.5","@types/react-dom":"^17.0.5","@types/react-reconciler":"^0.26.1","@typescript-eslint/eslint-plugin":"^4.23.0","@typescript-eslint/parser":"^4.23.0","eslint":"^7.26.0","eslint-config-airbnb":"^18.2.1","eslint-config-prettier":"^8.3.0","eslint-plugin-import":"^2.23.1","eslint-plugin-jest":"^24.3.6","eslint-plugin-jsx-a11y":"^6.4.1","eslint-plugin-prettier":"^3.4.0","eslint-plugin-react":"^7.23.2","eslint-plugin-react-hooks":"^4.2.0","jest":"^26.6.3","jest-graphviz":"^0.4.0","prettier":"^2.3.0","react":"^17.0.2","react-test-renderer":"^17.0.2","rollup":"^2.48.0","rollup-plugin-delete":"^2.0.0","rollup-plugin-dts":"^3.0.1","rollup-plugin-terser":"^7.0.2","rollup-plugin-typescript2":"^0.30.0","ts-jest":"^26.5.6","ts-node":"^9.1.1","typescript":"^4.2.4"},"peerDependencies":{"react":">=16.8.0 || >=17"},"releases":[{"from":"2022-06-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":0},{"from":"2022-04-06T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":1},{"from":"2022-01-06T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":1},{"from":"2021-07-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":3},{"from":"2020-07-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":7}],"hasTestScript":true,"readme":"[![NodeCI](https://github.com/ts-graphviz/react/workflows/NodeCI/badge.svg)](https://github.com/ts-graphviz/react/actions?workflow=NodeCI)\n[![npm version](https://badge.fury.io/js/%40ts-graphviz%2Freact.svg)](https://badge.fury.io/js/%40ts-graphviz%2Freact)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](http://makeapullrequest.com)\n[![tested with jest](https://img.shields.io/badge/tested_with-jest-99424f.svg)](https://github.com/facebook/jest)\n[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg)](https://github.com/prettier/prettier)\n[![Open in Visual Studio Code](https://open.vscode.dev/badges/open-in-vscode.svg)](https://open.vscode.dev/ts-graphviz/react)<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->\n[![All Contributors](https://img.shields.io/badge/all_contributors-3-orange.svg?style=flat-square)](#contributors-)\n<!-- ALL-CONTRIBUTORS-BADGE:END -->\n\n\n# @ts-graphviz/react\n\nGraphviz-dot Renderer using React.\n\n## Installation\n\nThe module can then be installed using [npm](https://www.npmjs.com/):\n\n[![NPM](https://nodei.co/npm/@ts-graphviz/react.png)](https://nodei.co/npm/@ts-graphviz/react/)\n\n```bash\n# yarn\n$ yarn add @ts-graphviz/react react\n# or npm\n$ npm install -S @ts-graphviz/react react\n```\n\n> Install [React](https://github.com/facebook/react/) as peerDependencies at the same time.\n\n## Example\n\n```jsx\nimport React from 'react';\nimport { Digraph, Node, Subgraph, Edge, DOT, renderToDot } from '@ts-graphviz/react';\n\nconst Example = () => (\n  <Digraph\n    rankdir=\"TB\"\n    edge={{\n      color: 'blue',\n      fontcolor: 'blue',\n    }}\n    node={{\n      shape: 'none',\n    }}\n  >\n    <Node\n      id=\"nodeA\"\n      shape=\"none\"\n      label={\n        <DOT.TABLE BORDER=\"0\" CELLBORDER=\"1\" CELLSPACING=\"0\">\n          <DOT.TR>\n            <DOT.TD>left</DOT.TD>\n            <DOT.TD PORT=\"m\">middle</DOT.TD>\n            <DOT.TD PORT=\"r\">right</DOT.TD>\n          </DOT.TR>\n        </DOT.TABLE>\n      }\n    />\n\n    <Subgraph id=\"cluster\" label=\"Cluster\" labeljust=\"l\">\n      <Node id=\"nodeB\" label=\"This is label for nodeB.\" />\n    </Subgraph>\n    <Edge targets={['nodeB', 'nodeA:m']} comment=\"Edge from node A to B\" label={<DOT.B>A to B</DOT.B>} />\n  </Digraph>\n);\n\nconst dot = renderToDot(<Example />);\n\nconsole.log(dot);\n```\n\n### Output dot\n\n```dot\ndigraph {\n  rankdir = \"TB\";\n  edge [\n    color = \"blue\",\n    fontcolor = \"blue\",\n  ];\n  node [\n    shape = \"none\",\n  ];\n  \"nodeA\" [\n    shape = \"none\",\n    label = <<TABLE BORDER=\"0\" CELLBORDER=\"1\" CELLSPACING=\"0\"><TR><TD>left</TD><TD PORT=\"m\">middle</TD><TD PORT=\"r\">right</TD></TR></TABLE>>,\n  ];\n  subgraph \"cluster\" {\n    labeljust = \"l\";\n    label = \"Cluster\";\n    \"nodeB\" [\n      label = \"This is label for nodeB.\",\n    ];\n  }\n  // Edge from node A to B\n  \"nodeB\" -> \"nodeA\":\"m\" [\n    label = <<B>A to B</B>>,\n  ];\n}\n```\n\n![dot](./example/example.svg)\n\n## See Also\n\nGraphviz-dot Test and Integration\n\n- [ts-graphviz](https://github.com/ts-graphviz/ts-graphviz)\n  - Graphviz library for TypeScript.\n- [jest-graphviz](https://github.com/ts-graphviz/jest-graphviz)\n  - Jest matchers that supports graphviz integration.\n- [setup-graphviz](https://github.com/ts-graphviz/setup-graphviz)\n  - GitHub Action to set up Graphviz cross-platform(Linux, macOS, Windows).\n\n## Contributors\n\nThanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/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://blog.kamiazya.tech/\"><img src=\"https://avatars0.githubusercontent.com/u/35218186?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Yuki Yamazaki</b></sub></a><br /><a href=\"https://github.com/ts-graphviz/react/commits?author=kamiazya\" title=\"Code\">💻</a> <a href=\"https://github.com/ts-graphviz/react/commits?author=kamiazya\" title=\"Tests\">⚠️</a> <a href=\"#ideas-kamiazya\" title=\"Ideas, Planning, & Feedback\">🤔</a> <a href=\"https://github.com/ts-graphviz/react/commits?author=kamiazya\" title=\"Documentation\">📖</a></td>\n    <td align=\"center\"><a href=\"https://github.com/nagasawaryoya\"><img src=\"https://avatars.githubusercontent.com/u/53528726?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>nagasawaryoya</b></sub></a><br /><a href=\"https://github.com/ts-graphviz/react/commits?author=nagasawaryoya\" title=\"Code\">💻</a> <a href=\"https://github.com/ts-graphviz/react/commits?author=nagasawaryoya\" title=\"Tests\">⚠️</a></td>\n    <td align=\"center\"><a href=\"https://github.com/tokidrill\"><img src=\"https://avatars.githubusercontent.com/u/42460318?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>YukiSasaki</b></sub></a><br /><a href=\"https://github.com/ts-graphviz/react/commits?author=tokidrill\" title=\"Code\">💻</a> <a href=\"https://github.com/ts-graphviz/react/commits?author=tokidrill\" title=\"Tests\">⚠️</a></td>\n  </tr>\n</table>\n\n<!-- markdownlint-restore -->\n<!-- prettier-ignore-end -->\n\n<!-- ALL-CONTRIBUTORS-LIST:END -->\n\nThis project follows the [all-contributors](https://github.com/all-contributors/all-contributors)\nspecification. Contributions of any kind welcome!\n\n## License\n\nThis software is released under the MIT License, see [LICENSE](./LICENSE)."},"npm":{"downloads":[{"from":"2022-07-04T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":5},{"from":"2022-06-28T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":25},{"from":"2022-06-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":173},{"from":"2022-04-06T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":664},{"from":"2022-01-06T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":1234},{"from":"2021-07-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":3766}],"starsCount":0},"github":{"homepage":"https://www.npmjs.com/package/@ts-graphviz/react","starsCount":24,"forksCount":3,"subscribersCount":3,"issues":{"count":331,"openCount":2,"distribution":{"3600":20,"10800":2,"32400":7,"97200":42,"291600":49,"874800":86,"2624400":71,"7873200":33,"23619600":18,"70858800":3,"212576400":0},"isDisabled":false},"contributors":[{"username":"allcontributors[bot]","commitsCount":6},{"username":"kamiazya","commitsCount":136},{"username":"nagasawaryoya","commitsCount":4},{"username":"dependabot[bot]","commitsCount":11},{"username":"dependabot-preview[bot]","commitsCount":49},{"username":"tokidrill","commitsCount":1}],"commits":[{"from":"2022-06-28T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":0},{"from":"2022-06-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":0},{"from":"2022-04-06T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":1},{"from":"2022-01-06T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":2},{"from":"2021-07-05T00:00:00.000Z","to":"2022-07-05T00:00:00.000Z","count":16}]},"source":{"files":{"readmeSize":5422,"testsSize":18846,"hasNpmIgnore":true},"badges":[{"urls":{"original":"https://nodei.co/npm/@ts-graphviz/react.png","shields":"https://img.shields.io/npm/v/@ts-graphviz/react.svg","content":"https://img.shields.io/npm/v/@ts-graphviz/react.json"},"info":{"service":"npm","type":"version"}}],"linters":["editorconfig","eslint","prettier"],"outdatedDependencies":{"react-reconciler":{"required":"^0.26.2","stable":"0.29.0","latest":"0.30.0-next-4cd788aef-20220630"},"react-dom":{"required":"^17.0.2","stable":"18.2.0","latest":"18.3.0-next-4cd788aef-20220630"}}}},"evaluation":{"quality":{"carefulness":0.45999999999999996,"tests":0.6,"health":0.5,"branding":0.15},"popularity":{"communityInterest":36,"downloadsCount":221.33333333333334,"downloadsAcceleration":-2.003348554033485,"dependentsCount":0},"maintenance":{"releasesFrequency":0.4592465753424658,"commitsFrequency":0.2891095890410959,"openIssues":1,"issuesDistribution":0.9279660108584769}},"score":{"final":0.6062158431529526,"detail":{"quality":0.7796523410303536,"popularity":0.0643113142505561,"maintenance":0.9994605167318626}}}