Chart.js #5884 test02
by Akihiko Kusanagi
HTML
<script src="https://cdn.jsdelivr.net/gh/nagix/nagix.github.io@chartjs/Chart.5884.js"></script>
<div style="border:1px solid #000000;">
<canvas id="myChart"></canvas>
</div>
JavaScript
var canvas = document.getElementById('myChart');
var myBarChart = Chart.Bar(canvas,{
data: {
labels: ["January", "February", "March", "April", "May", "June", "July", "August"],
datasets: [
{
label: "My First dataset",
backgroundColor: "rgba(255,99,132,0.2)",
borderColor: "rgba(255,99,132,1)",
borderWidth: 2,
hoverBackgroundColor: "rgba(255,99,132,0.4)",
hoverBorderColor: "rgba(255,99,132,1)",
data: [65, 59, 20, 81, 56, 55, 40, 50],
}
]
},
options: {
scales: {
yAxes:[{
gridLines: {
color:"rgba(255,99,132,0.2)"
}
}],
xAxes:[{
gridLines: {
display:false
}
}]
}
}
});