2018-09-24 15:36:35 +00:00
|
|
|
```jsx
|
2018-11-15 18:16:23 +00:00
|
|
|
import { D3Chart, Legend } from 'components';
|
2018-09-24 15:36:35 +00:00
|
|
|
|
|
|
|
const noop = () => {};
|
|
|
|
|
|
|
|
const data = [
|
|
|
|
{
|
|
|
|
date: '2018-05-30T00:00:00',
|
|
|
|
Hoodie: { value: 21599 },
|
|
|
|
Sunglasses: { value: 38537 },
|
|
|
|
Cap: { value: 106010 },
|
|
|
|
},
|
|
|
|
{
|
|
|
|
date: '2018-05-31T00:00:00',
|
|
|
|
Hoodie: { value: 14205 },
|
|
|
|
Sunglasses: { value: 24721 },
|
|
|
|
Cap: { value: 70131 },
|
|
|
|
},
|
|
|
|
{
|
|
|
|
date: '2018-06-01T00:00:00',
|
|
|
|
Hoodie: { value: 10581 },
|
|
|
|
Sunglasses: { value: 19991 },
|
|
|
|
Cap: { value: 53552 },
|
|
|
|
},
|
|
|
|
{
|
|
|
|
date: '2018-06-02T00:00:00',
|
|
|
|
Hoodie: { value: 9250 },
|
|
|
|
Sunglasses: { value: 16072 },
|
|
|
|
Cap: { value: 47821 },
|
|
|
|
},
|
|
|
|
];
|
|
|
|
|
|
|
|
const MyChart = () => (
|
|
|
|
<div>
|
|
|
|
<Chart data={ data } title="Example Chart" layout="comparison" />
|
|
|
|
</div>
|
|
|
|
);
|
|
|
|
```
|