Git Product home page Git Product logo

react-g2plot's Introduction

React-G2Plot

react-g2plot is an unofficial react component wrapper for @antv/g2plot.

npm Build Status npm React Supported npm

Install

$ npm install react-g2plot

Usage

import ReactDOM from 'react-dom';
import React from 'react';

import { Line } from '@antv/g2plot';      // import plot from G2Plot
import ReactG2Plot from 'react-g2plot';   // import React wrapper

ReactDOM.render(
  <ReactG2Plot
    className="your-classname"
    Ctor={Line}
    options={options}
  />,
  mountNode,
);

Documents

All documents about plot and options are here.

Development

$ npm install

# run test case
$ npm run test

# run live demo
$ npm run demo

LICENSE

MIT@hustcc.

react-g2plot's People

Contributors

hustcc avatar jgcmarins avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

react-g2plot's Issues

Issue while rendering the HeatMap Chart for the 2nd time.

We have a feature that uses your HeatMap chart to display some data. I have a refresh icon that gives a chart preview after selecting the values. Thereafter, Every time when I change the xAxis and yAxis values from the drop-down, I am trying to re-render the chart to preview it. But, I am getting the below error.
Capture

container.ts:92 Uncaught TypeError: Cannot read property 'filter' of undefined
at Group.Container.getBBox (container.ts:92)
at MatrixLegend.getBBox (legend.ts:108)
at padding.ts:95
at each (each.ts:11)
at PaddingController.processOuterPadding (padding.ts:93)
at HeatmapLayer.ViewLayer.getViewRange (view-layer.ts:705)
at HeatmapLayer.ViewLayer.init (view-layer.ts:248)
at HeatmapLayer.Layer.render (layer.ts:110)
at HeatmapLayer.ViewLayer.render (view-layer.ts:295)
at plot.ts:222
at each (each.ts:11)
at Heatmap.BasePlot.eachLayer (plot.ts:226)
at Heatmap.BasePlot.render (plot.ts:222)
at default_1. (index.js:28)
at helper.js:17

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.