New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

react-pathjs-chart

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-pathjs-chart

React components - charts (Pie,SmoothLine) and other components (Tree) using path-js.

latest
Source
npmnpm
Version
0.3.5
Version published
Weekly downloads
22
-12%
Maintainers
1
Weekly downloads
 
Created
Source

Chart library

These component offers react components - charts (Pie,Bar,SmoothLine,StockLine,Scatterplot,Tree,Radar) using paths-js.

It is based on clone of these examples from path-js and is extended so that it is easier to use it.

  • configuration of formats, labels, colors, axis, ticks, lines, animations, ...
  • support for chart animation - using vivus vivus
  • instead of accessor function you can use string key to determine the accessor key in data
  • server rendering
  • wrapped to be used by package managers (npm, bower) or standalone package

Demo & Examples

Live demo

To build the examples locally, run:

npm install
gulp dev

Then open localhost:8000 in a browser.

Installation

The easiest way to use this component is to install it from NPM and include it in your own React build process (using Browserify, Webpack, etc).

You can also use the standalone build by including dist/react-pathjs-chart.js in your page. If you use this, make sure you have already included React, and it is available as a global variable.

npm install react-pathjs-chart --save

Usage

import {Pie,Bar, SmoothLine,StockLine,Scatterplot,Tree,Radar} from 'react-pathjs-chart';

<Pie data={data} options={options} accessorKey="population"  />
<Bar data={data} options={options} accessorKey="value" />
<SmoothLine data={data} options={options} xKey="x" yKey="y"/>
<StockLine data={data} options={options} xKey="x" yKey="y"/>
<Scatterplot data={data} options={options} xKey="episode" yKey="rating" />
<Tree data={treeData} options={options}  />
<Radar data={activity} options={options} />

Properties

  • data - chart data to visualize
  • accessor keys
    • Pie,Bar - accessorKey
    • SmoothLine,StockLine,Scatterplot - xKey, yKey
  • options - visual configuration of chart, enables to configure formats, labels, colors, axis, ticks, lines, animations, ...
  • noDataMessage - message to show if no data or empty data are specified

Notes

License

MIT. Copyright (c) 2015 Roman Samec

Keywords

react

FAQs

Package last updated on 18 Mar 2016

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