JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://static.fusioncharts.com/code/latest/fusioncharts.js"></script>
<script src="https://static.fusioncharts.com/code/latest/fusioncharts.charts.js"></script>
<div id="chart-container">Chart will render here</div>
JavaScript
FusionCharts.ready(function(){
myChart = new FusionCharts({
type : "pie2d",
renderAt : "chart-container",
width : "500",
height : "400",
dataFormat : "json",
dataSource : {
"chart": {
"caption" : "Voters count",
"subcaption" : "In each Iteration",
"captionFontSize" : "16",
"subcaptionFontSize" : "14",
"canvasBorderColor" : "#b3ffb3",
"canvasBgColor" : "#ffff99,#b3ffb3",
"useDataPlotColorForLabels": "1",
"showPercentInTooltip": "0",
"showLegend" : "1",
"showLabels" : "1",
"showValues" : "1"
},
"data" : [{
"label" : "Party H",
"color" : "#1a6600",
"value" : "4000"
},{
"label" : "Party J",
"value" : "4500"
},{
"label" : "Party G",
"value" : "3500"
},{
"label" : "Party C",
"value" : "6500"
}],
"annotations": {
"showBelow" : "0",
"width": "500",
"height": "100",
...