JSFiddle - React, Tailwind, and code Playground

by karthick6891

HTML

<script src="https://rawgit.com/nnnick/Chart.js/2.0.0-alpha3/Chart.js"></script>
<div id="canvas-holder" style="width:100%">
    <canvas id="chart-area" width="500" height="500" />
</div>

JavaScript

var config = {
    type: 'pie',
    data: {
        datasets: [{
            data: [
            		12, 32, 12, 7, 3, 2, 1
            ],
                backgroundColor: [
                "#235784",
                "#f7aa00",
                "#fad073",
                "#2f7b8f",
                "#40a8c4",
                "#bcdbdf",
                "#cae7ee",
            ],
        }],
        labels: [
            "Implementation",
            "Memory",
            "Bounds",
            "Null",
            "Stack Overflow",
            "Integer Overflow",
            "Misc"
        ]
    },
    options: {
        responsive: true,
        legend: {
     			display: true
				},
        title: {
            display: true,
            text: 'Bug Categories'
        },
        animation: {
            animateScale: true,
            animateRotate: true
        }
    }
};

var ctx = document.getElementById("chart-area").getContext("2d");
var myDoughnut = new Chart(ctx, config);