{"id":17565124,"url":"https://github.com/open-data-plan/g2plot-react","last_synced_at":"2025-04-04T07:04:01.597Z","repository":{"id":37960576,"uuid":"233783707","full_name":"open-data-plan/g2plot-react","owner":"open-data-plan","description":"G2Plot for React","archived":false,"fork":false,"pushed_at":"2025-03-24T17:43:26.000Z","size":40684,"stargazers_count":82,"open_issues_count":0,"forks_count":14,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-03-28T06:05:55.396Z","etag":null,"topics":["chart","component","data-visualization","g2","g2plot","react"],"latest_commit_sha":null,"homepage":"https://g2plot.opd.cool/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/open-data-plan.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-14T07:35:24.000Z","updated_at":"2025-03-24T17:43:22.000Z","dependencies_parsed_at":"2024-01-08T16:32:55.506Z","dependency_job_id":"de5635cc-ed91-435a-a36c-b1cda4c6ce80","html_url":"https://github.com/open-data-plan/g2plot-react","commit_stats":{"total_commits":1092,"total_committers":6,"mean_commits":182.0,"dds":"0.39652014652014655","last_synced_commit":"eaeeb30e75a7cb7e25e7b60189a29c2aca5c9917"},"previous_names":["kagawagao/g2plot-react"],"tags_count":79,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-data-plan%2Fg2plot-react","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-data-plan%2Fg2plot-react/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-data-plan%2Fg2plot-react/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-data-plan%2Fg2plot-react/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/open-data-plan","download_url":"https://codeload.github.com/open-data-plan/g2plot-react/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247135139,"owners_count":20889420,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chart","component","data-visualization","g2","g2plot","react"],"created_at":"2024-10-21T14:09:29.443Z","updated_at":"2025-04-04T07:04:01.527Z","avatar_url":"https://github.com/open-data-plan.png","language":"TypeScript","readme":"\u003cp align=\"center\"\u003e\n\u003cimg src=\"./assets/logo.svg\"\u003e\n\u003c/p\u003e\n\n# @opd/g2plot-react\n\n\u003e [G2Plot](https://g2plot.antv.vision/) for React\n\n[![Build Status](https://dev.azure.com/kagawagao/OPD/_apis/build/status/open-data-plan.g2plot-react?branchName=master)](https://dev.azure.com/kagawagao/OPD/_build/latest?definitionId=1\u0026branchName=master)\n[![build](https://github.com/open-data-plan/g2plot-react/workflows/build/badge.svg)](https://github.com/open-data-plan/g2plot-react/actions?query=workflow%3Abuild)\n[![npm](https://img.shields.io/npm/v/@opd/g2plot-react.svg)](https://www.npmjs.com/package/@opd/g2plot-react)\n[![npm](https://img.shields.io/npm/dm/@opd/g2plot-react.svg)](https://www.npmjs.com/package/@opd/g2plot-react)\n[![npm](https://img.shields.io/npm/l/@opd/g2plot-react.svg)](https://www.npmjs.com/package/@opd/g2plot-react)\n[![codecov](https://codecov.io/gh/open-data-plan/g2plot-react/branch/master/graph/badge.svg)](https://codecov.io/gh/open-data-plan/g2plot-react)\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fopen-data-plan%2Fg2plot-react.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fopen-data-plan%2Fg2plot-react?ref=badge_shield)\n\n## Install\n\n```\nnpm install @opd/g2plot-react\n```\n\n## Usage\n\n```tsx\nimport React, { useRef } from 'react'\nimport { LineChart, LineChartProps } from '@opd/g2plot-react'\n\nconst config: LineChartProps = {\n  height: 350,\n  autoFit: true,\n  xField: 'year',\n  yField: 'value',\n  smooth: true,\n  meta: {\n    value: {\n      max: 15,\n    },\n  },\n  data: [\n    { year: '1991', value: 3 },\n    { year: '1992', value: 4 },\n    { year: '1993', value: 3.5 },\n    { year: '1994', value: 5 },\n    { year: '1995', value: 4.9 },\n    { year: '1996', value: 6 },\n    { year: '1997', value: 7 },\n    { year: '1998', value: 9 },\n    { year: '1999', value: 11 },\n  ],\n}\n\nexport default () =\u003e {\n  const chartRef = useRef()\n  return \u003cLineChart {...config} chartRef={chartRef} /\u003e\n}\n```\n\n[![Edit g2plot-react-example](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/g2plot-react-example-xx3gp?fontsize=14\u0026hidenavigation=1\u0026theme=dark)\n\n## API\n\nAll config defined in `G2Plot` [document](https://g2plot.antv.vision/zh/docs/manual/introduction) can be used as `props`\n\n## Develop\n\n```\nnpm install\nnpm run build\n```\n\n\n## License\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fopen-data-plan%2Fg2plot-react.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Fopen-data-plan%2Fg2plot-react?ref=badge_large)","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopen-data-plan%2Fg2plot-react","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopen-data-plan%2Fg2plot-react","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopen-data-plan%2Fg2plot-react/lists"}