JSFiddle - React, Tailwind, and code Playground

by mlmason

HTML

<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/data.js"></script>
<script src="https://code.highcharts.com/modules/drilldown.js"></script>

<div id="container" style="min-width: 310px; height: 400px; margin: 0 auto"></div>

JavaScript

$(function () {
    // Create the chart
    Highcharts.chart('container', {
        chart: {
            type: 'column'
        },
        title: {
            text: 'Michigan and Michigan Locations'
        },
        subtitle: {
            text: ''
        },
        xAxis: {
            type: 'category'
        },
        yAxis: {
            title: {
                text: 'Number of Mentions'
            }

        },
        legend: {
            enabled: false
        },
        plotOptions: {
            series: {
                borderWidth: 0,
                dataLabels: {
                    enabled: true,
                    format: '{point.y:.0f}'
                }
            }
        },

        /*tooltip: {
            headerFormat: '<span style="font-size:11px">{series.name}</span><br>',
            pointFormat: '<span style="color:{point.color}">{point.name}</span>: <b>{point.y:.2f}%</b> of total<br/>'
        },*/

        series: [{
            name: 'Number of Mentions',
            colorByPoint: true,
            data: [{
                name: 'Grand Rapids',
                y: 8,
                drilldown: 'Grand Rapids'
            }, {
                name: 'Great Lakes',
                y: 14,
                drilldown: 'Great Lakes'
            }, {
                name: 'Michigan',
                y: 335,
                drilldown: 'Michigan'
            }, {
                name: 'Flint',
                y: 58,
                drilldown: 'Flint'
            }, 
             {
                name: 'Upper Peninsula',
                y: 9,
                drilldown: 'Upper Penisula'
            },
             {
                name: 'Pontiac',
                y: 5,
                drilldown: 'Pontiac'
            },
             {
                name: 'Sault Ste. Marie/Soo Locks',
                y: 4,
                drilldown: 'Sault Ste. Marie/Soo Locks'
            },
                  {
                name: 'Saginaw',
         ...