Socket
Book a DemoInstallSign in
Socket

react-barchart-envelope

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-barchart-envelope

React component for simple barchart envelope

latest
Source
npmnpm
Version
0.2.0
Version published
Maintainers
1
Created
Source

react-barchart-envelope

React component for simple barchart envelope

react-barchart-envelope

Demo

http://fraserxu.me/react-barchart-envelope/

Installation

$ npm install react-barchart-envelope --save

Usage

var React = require('react')
var BarchartEnvelope = require('react-barchart-envelope')

var Graph = React.createClass({
  render: function() {

    var data = [15, 12, 25, 8, 20, 14, 15, 3, 9, 29, 23, 12, 10, 26, 17, 25, 4, 29, 23, 12, 10, 26, 17, 25, 4, 29, 23, 12, 10, 26, 17, 25]

    var onBarchartClick = function(d) {
      console.log(d)
    }

    return (
      <div>
        <BarchartEnvelope data={data} onBarchartClick={onBarchartClick} hoverEffect={true}/>
      </div>
    )
  }
})

React.render(<Graph />, document.body)

Options

  • onBarchartClick={onBarchartClick} barchart click event listener
  • hoverEffect={true} set true to have hover effect on the chart
  • tooltip={true} set true to add tooltip to the chart
  • width set the width of the chart
  • height set the height of the chart
  • strokeColor set the color of the stroke
  • strokeWidth set the width of the stroke

License

MIT

Keywords

react

FAQs

Package last updated on 16 Dec 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts