JSFiddle - React, Tailwind, and code Playground
by alcosbarco
JavaScript
var strChart2=`
{
"type": "XYChart",
"data": [{
"Mes": "ENE 2019",
"Cobertura": 44,
"Exportacion": 6816,
"importacion": 4816
}, {
"Mes": "FEB 2019",
"Cobertura": 92,
"Exportacion": 6254,
"importacion": 4816
}],
"xAxes": [{
"type": "CategoryAxis",
"id": "id-1",
"dataFields": {
"category": "Mes"
},
"renderer": {
"grid": {
"template": {
"type": "Grid",
"location": 0
}
},
"minGridDistance": 20
}
}],
"yAxes": [{
"type": "ValueAxis",
"id": "axis1",
"title": {
"type": "Label",
"text": "Series 1"
},
"renderer": {
"maxLabelPosition": 0.98
}
}, {
"type": "ValueAxis",
"id": "axis2",
"title": {
"type": "Label",
"text": "Series 2"
},
"renderer": {
"opposite": true,
"maxLabelPosition": 0.98
}
}],
"series": [{
"type": "ColumnSeries",
"name": "Exportacion",
"columns": {
"template": {
"type": "Column",
...