JSFiddle - React, Tailwind, and code Playground

by L1NU5

HTML

<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.1.2/Chart.min.js"></script>
<canvas id="myChart" width="400" height="200"></canvas>

CSS

#myChart {
   background-color: #666;
}

JavaScript

var ctx = document.getElementById("myChart");

Chart.defaults.global.defaultFontColor= '#fff';

var myChart = new Chart(ctx, {
  type: 'line',
  data: {
    labels: ["Red", "Blue", "Yellow", "Green", "Purple", "Orange"],
    datasets: [{
      label: '# of Votes',
      data: [12, 19, 3, 5, 2, 3],
      backgroundColor: 'rgba(185, 214, 200, 0.75)',
      borderColor: 'rgba(255, 255, 255, 0.5)'
    }]
  },
  options: {
    scales: {
    	xAxes: [{
      	gridLines: {
        	display: false
        }
      }],
      yAxes: [{
        ticks: {
        	beginAtZero:true
        }
      }]
    }
  }
});