Skip to content

Commit

Permalink
Merge branch 'master' of github.com:spotify/reactochart into gh-pages-v3
Browse files Browse the repository at this point in the history
* 'master' of github.com:spotify/reactochart:
  v3.0.0 release
  3.0.0
  v3.0.0 release (#195)
  Revert "Added Precommit hooks (#191)" (#193)
  Remove docs from build (#192)
  Added Precommit hooks (#191)
  Update docs in master (#189)
  2.0.2 release (#188)
  Bump eslint-utils from 1.4.0 to 1.4.3 (#185)
  Bump mixin-deep from 1.3.1 to 1.3.2 (#186)
  Fix warnings in tests and add SankeyNodeTerminal tests (#184)
  decorate events and remove original decorations (#182)
  Changelog casing fix
  • Loading branch information
acmei committed Dec 16, 2019
2 parents 4a9ff49 + 311744f commit b78677d
Show file tree
Hide file tree
Showing 115 changed files with 140,064 additions and 8,454 deletions.
6 changes: 6 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,9 @@

# Ignore lessons
/docs/src/lessons

# Ignore docs build
/docs/build/*

# test setup
/tests/jsdom/setup.js
13 changes: 8 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
language: node_js
node_js:
- "6"
- "7"
- "8"
- "9"
- '8'
- '9'
- '10'
- '11'
- '12'
env:
- CXX=g++-4.8
addons:
Expand All @@ -12,7 +13,9 @@ addons:
- ubuntu-toolchain-r-test
packages:
- g++-4.8
cache:
npm: false
before_install:
- npm i -g npm@latest
install:
- npm ci
- npm ci
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## 3.0.0 (2019-12-16)

- [#187](https://github.com/spotify/reactochart/pull/187) Dependency upgrades
- [#194](https://github.com/spotify/reactochart/pull/194) Addition of pre-commit hooks
- [#201](https://github.com/spotify/reactochart/pull/201) PieChart updates
- [#207](https://github.com/spotify/reactochart/pull/207) Documentation updates

## 2.0.2 (2019-11-04)

- [#182](https://github.com/spotify/reactochart/pull/182) Decorate XYPlot onMouseEnter and onMouseLeave events - thanks @tanayv!
Expand Down
27 changes: 13 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,29 +11,28 @@

# Overview

[![Greenkeeper badge](https://badges.greenkeeper.io/spotify/reactochart.svg)](https://greenkeeper.io/)

Reactochart is a library of React components for creating data visualization charts and graphs. Components include **line chart**, **bar chart**, **area chart**, **heat maps**, **scatterplot**, **histogram**, **pie chart**, **sankey diagram**, and **tree map**.

# Getting started

1. Install reactochart using npm.


```
npm i reactochart --save
```

2. Then you can import an individual Reactochart component:


```jsx
import LineChart from 'reactochart/LineChart'
import LineChart from 'reactochart/LineChart';
```

3. If you prefer, you can import all of Reactochart at once, though this may hinder some optimizations, such as webpack tree-shaking:


```jsx
import {XYPlot, XAxis, YAxis, LineChart} from 'reactochart';
import { XYPlot, XAxis, YAxis, LineChart } from 'reactochart';
```

or
Expand All @@ -44,32 +43,32 @@ import * as Reactochart from 'reactochart';

4. Import reactochart's base styles


```jsx
import 'reactochart/styles.css'
import 'reactochart/styles.css';
```

5. Build your first chart and see it rendered! For example, the following code snippet:


```jsx
import XYPlot from 'reactochart/XYPlot';
import XAxis from 'reactochart/XAxis';
import YAxis from 'reactochart/YAxis';
import LineChart from 'reactochart/LineChart';
import 'reactochart/styles.css'
import 'reactochart/styles.css';

const MyFirstLineChart = (props) => (
const MyFirstLineChart = props => (
<XYPlot>
<XAxis title="Phase" />
<YAxis title="Intensity" />
<LineChart
data={Array(100).fill().map((e, i) => i+1)}
data={Array(100)
.fill()
.map((e, i) => i + 1)}
x={d => d}
y={d => Math.sin(d*.1)}
y={d => Math.sin(d * 0.1)}
/>
</XYPlot>
)
);
```

results in this:
Expand Down Expand Up @@ -153,7 +152,7 @@ If you'd like to contribute to the development this project, first fork & clone

- Run `npm run dev` to run the development server (webpack-dev-server), which will serve a live development version of the examples at [localhost:9876](http://localhost:9876).
- Make changes to the library code in the `src` directory, and/or changes to the examples in the `examples/src` directory.
- If you'd like to make changes or add further component documentation, follow the example on [`react-docgen`](https://github.com/reactjs/react-docgen#example).
- If you'd like to make changes or add further component documentation, follow the example on [`react-docgen`](https://github.com/reactjs/react-docgen#example).
- Once you're happy with your library and/or documentation changes, run `npm run docs`. This allows the documentation build to run with your updated `src` code. `git add` and `git commit` the updated build.
- `git push` to your forked version of the repo.
- Open a Github pull request with your changes against `master`. 🎉
Expand Down
Loading

0 comments on commit b78677d

Please sign in to comment.