GithubHelp home page GithubHelp logo

cong876 / react-easy-chart Goto Github PK

View Code? Open in Web Editor NEW

This project forked from experience-experiments/react-easy-chart

0.0 2.0 0.0 9.26 MB

Easy to use React Charting library

Home Page: http://rma-consulting.github.io/react-easy-chart

License: BSD 3-Clause "New" or "Revised" License

HTML 0.50% JavaScript 99.41% CSS 0.09%

react-easy-chart's Introduction

React Easy Chart

animated graph

Introduction

This set of graphing components aims to be the easiest and fastest way of implementing a graph within a React application.

The graphs all have the following features:

  • Easy to set up with only a requirement for data to render a chart
  • Support realtime data feeds by reacting to data changes passed into the props automatically
  • Fast rendering by using React to minimise the changes to the DOM as a result of data or props changes
  • Configurable via props to allow features such as grids, width, height, axis and many more features to be added
  • Responsive and Reactive graphs to fit to any device
  • Interactive via mouse and click events allowing interesting applications to be built without graphing knowledge

Under the hood we use the fantastic D3 to create and render the charts into SVG. D3 requires some learning and will ultimately provide more flexible charts. The aim of React Easy Chart is to avoid that learning and have a common set of charts that can be set up in minutes.

We have concentrated on making an API that is consistent across a different set of graphs so allowing different graphs to be chosen for the same data set. Currently we provide a bar, line, area, scatter and pie chart.

Installation

npm install react-easy-chart --save

The chart component you wish to use can then be simply imported.
Area chart:

import {AreaChart} from 'react-easy-chart';

Bar chart:

import {BarChart} from 'react-easy-chart';

Line chart:

import {LineChart} from 'react-easy-chart';

Pie chart:

import {PieChart} from 'react-easy-chart';

Scatter chart:

import {ScatterChart} from 'react-easy-chart';

Chart Legend:

import {Legend} from 'react-easy-chart';

Documentation

Each of the charts have had extensive documentation produced for them with working examples. These can be found at http://rma-consulting.github.io/react-easy-chart/docs

Contributing

We welcome pull requests and forks of the current graph implementations. If you are able to follow the API we have set out and are developing a chart we currently do not have we would love to add to our existing library.

Background and Motivation

The project started by trying to optimize D3 charts for React. After some reading and trial and error we came across this blog post http://oli.me.uk/2015/09/09/d3-within-react-the-right-way/ Oliver provided us with a solution that can utilize the react shadow DOM by creating a faux DOM to attach the SVG elements to. This is in our opinion the best current solution.

The complexity of developing D3 based graphs intermittently often means that even experienced JavaScript developers can take days getting back up to speed for making the most simple of Graphs. The React Easy Chart Library is flexible and robust enough to avoid needing to remember D3 syntax when simple graphs are required.

Version

npm version

Build Status

Build Status

react-easy-chart's People

Contributors

jonathanperryrma avatar nicholastettenborn avatar petermason avatar harunhasdal avatar sat- avatar

Watchers

James Cloos avatar  avatar

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.