JSFiddle - React, Tailwind, and code Playground
HTML
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="http://code.highcharts.com/modules/exporting.js"></script>
<div id="container" style="min-width: 400px; height: 400px; margin: 0 auto"></div>
JavaScript
$(function () {
var chart;
$(document).ready(function() {
chart = new Highcharts.Chart({
chart: {
renderTo: 'container',
type: 'bar'
},
title: {
text: 'Marks in 5th grade'
},
xAxis: {
reversed:true,
categories: ['John', 'Sandy', 'Carl', 'Maria'],
title: {
text: null
}
},
yAxis: {
reversed:true,
min: 0,
max:6,
title: {
text: 'Marks from 6 (very bad) to 1 (yery good)',
align: 'high'
},
labels: {
overflow: 'justify'
}
},
plotOptions: {
bar: {
dataLabels: {
enabled: true
}
}
},
credits: {
enabled: false
},
series: [{
name: 'Year 2012',
data: [1,] }, {
name: 'Year 2011',
data: [1.99]
}, {
name: 'Year 2010',
data: [1.74]
}]
});
});
});