# react-basic-charts

> A very basic charts library for React. For now it has only a basic bar chart.

Latest version **0.1.1** (published 2020-07-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-basic-charts
pnpm add react-basic-charts
yarn add react-basic-charts
bun add react-basic-charts
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2020-07-19 |
| First published | 2020-07-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=10 |
| Dependencies | 2 |
| Unpacked size | 55.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Emmanuel |
| Maintainers | exifers |
| Keywords | react, chart, graphic, bars, basic |

## Links

- npm: https://www.npmjs.com/package/react-basic-charts
- Homepage: https://github.com/Exifers/react-basic-charts
- npm.io page: https://npm.io/package/react-basic-charts

## Dependencies (2)

- [react-popper](https://npm.io/package/react-popper.md) ^2.2.3
- [@popperjs/core](https://npm.io/package/@popperjs/core.md) ^2.4.4

## Alternatives

- [d3-force-3d](https://npm.io/package/d3-force-3d.md) — 1.0M weekly downloads
- [ng2-charts](https://npm.io/package/ng2-charts.md) — 486.8K weekly downloads
- [@arcgis/core](https://npm.io/package/@arcgis/core.md) — 257.8K weekly downloads
- [react-sparklines](https://npm.io/package/react-sparklines.md) — 249.3K weekly downloads
- [react-native-gifted-charts](https://npm.io/package/react-native-gifted-charts.md) — 182.3K weekly downloads

## Recent versions

- 0.1.1 (latest) — 2020-07-19
- 0.1.0 — 2020-07-18

## README

# react-basic-charts
A very basic charts library for React. For now it has only a basic bar chart.

![](https://raw.githubusercontent.com/Exifers/react-basic-charts/master/doc/bars.png)

[live demo](https://react-basic-charts.netlify.app/)

## Usage
```bash
// npm
npm install react-basic-charts

// yarn
yarn add react-basic-charts
```

```tsx
import React from 'react';
import { Chart } from 'react-basic-charts';
import 'react-basic-charts/index.css';

const data = {
  Monday: [
    10,
    15,
    25
  ],
  Tuesday: [
    15,
    25,
    0
  ],
  Wednesday: [
    20,
    25,
    30
  ],
  Thirsday: [
    30,
    35,
    10
  ],
  Friday: [
    35,
    10,
    20
  ],
  Saturday: [
    30,
    25,
    30
  ],
  Sunday: [
    20,
    10,
    5
  ]
};

function MyComponent() {
  return (
    <Chart
      height={500}
      colors={['#A6E7DB', '#2D7A7A', '#76C7D2']}
      data={data}
      displayValue={(value: number) => '$ ' + value}
      />
  )
}
```

---
_Source: https://npm.io/package/react-basic-charts · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
