@sebgroup/green-react-charts
TypeScript icon, indicating that this package has built-in type declarations

1.3.0 • Public • Published

Green React Charts

React Green charting components

Install

yarn add @sebgroup/green-react-charts
npm install -S @sebgroup/green-react-charts

Use

First you need to import the base styles for charts:

@use '~@sebgroup/green-charts/scss';

Then you can start using the Chart react component:

import { Chart, ChartSettings } from '@sebgroup/green-react-charts'

export const MyChart = () => {
  const settings: ChartSettings = {
    title: 'My mixed chart',
    data: [
      {
        title: 'Sales',
        type: 'bar',
        columns: [100, 200, 300, -50],
      },
      {
        title: 'Prognosis',
        type: 'spline',
        columns: [0, 10, 150, 330],
      },
    ],
    categories: ['Jan', 'Feb', 'Mar', 'Apr'],
  }

  return <Chart settings={settings} />
}

Readme

Keywords

none

Package Sidebar

Install

npm i @sebgroup/green-react-charts

Weekly Downloads

9

Version

1.3.0

License

Apache-2.0

Unpacked Size

60.8 kB

Total Files

7

Last publish

Collaborators

  • vsjolander
  • sebopensource
  • johanobrink