Welcome aboard! We are happy you are here and wish you good net-raft!
// you must install npm install react-fusioncharts --save and npm install fusioncharts --save
import React from 'react';
import ReactDOM from 'react-dom';
import FusionCharts from 'fusioncharts';
import Charts from 'fusioncharts/fusioncharts.charts';
import ReactFC from 'react-fusioncharts';
Charts(FusionCharts);
const myDataSource = {
chart: {
caption: 'Your Caption',
subCaption: 'Your SubCaption',
numberPrefix: '$',
},
data: [
{
label: 'Label1',
value: '890000',
},
{
label: 'Label2',
value: '740000',
},
{
label: 'Label3',
value: '580000',
},
{
label: 'Label4',
value: '520000',
},
{
label: 'Label5',
value: '340000',
},
],
};
const chartConfigs = {
type: 'pie3d',
width: 600,
height: 400,
dataFormat: 'json',
dataSource: myDataSource,
};
ReactDOM.render(
<ReactFC {...chartConfigs} />,
document.getElementById('root'),
);
The most helpful REACT solutions
How to get client ip address using react ?REACT Click to see more ... 19.2K 421