JSFiddle - React, Tailwind, and code Playground
by Flexmonster Pivot Table
HTML
<link rel="stylesheet" href="https://s3.amazonaws.com/flexmonster/2.3/demo.css">
<script src="https://cdn.flexmonster.com/flexmonster.js"></script>
<div id="pivot-container-1"></div>
JavaScript
var pivot_table_1 = new Flexmonster({
container: "#pivot-container-1",
componentFolder: "https://cdn.flexmonster.com/",
width: "100%",
height: 378,
toolbar: true,
report: {
dataSource: {
filename: "data/dashboad-demo-data.json"
},
options: {
grid: {
type: "flat"
}
},
"slice": {
"rows": [{
"uniqueName": "Division"
}],
"columns": [{
"uniqueName": "Patient Status"
},
{
"uniqueName": "[Measures]"
}
],
"measures": [{
"uniqueName": "Treatment Cost",
"aggregation": "sum",
"format": "currency"
}]
},
"formats": [{
"name": "currency",
"currencySymbol": "$"
},
{
"name": "",
"decimalPlaces": 2
}
],
"tableSizes": {
"columns": [{
"idx": 0,
"width": 175
},
{
"idx": 1,
"width": 250
}
],
"rows": [{
"idx": 0,
"height": 40
},
{
"idx": 1,
"height": 50
},
]
},
}
});