JSFiddle - React, Tailwind, and code Playground

by Shinohara

HTML

<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/lodash.min.js"></script>
<script src="https://ts-3156.github.io/chasingchart/chasingchart-latest.js"></script>

<div id="container" style="min-width: 310px; max-width: 800px; height: 400px; margin: 0 auto"></div>
<button id="button" style="display: block; margin: 0 auto">Start</button>

JavaScript

var input = [{
        "options": {"title": {"text": "Demo"}, "subtitle": {"text": "1900"}},
        "data": {"Cat1": 500, "Cat2": 400, "Cat3": 300, "Cat4": 200, "Cat5": 100}
    }, {
        "options": {"title": {"text": "Demo"}, "subtitle": {"text": "2000"}},
        "data": {"Cat1": 500, "Cat2": 550, "Cat3": 300, "Cat4": 200, "Cat5": 100}
    }];

var chart = Chasingchart.chart('container');
chart.setData(input);

document.getElementById('button').addEventListener("click", function (event) {
  chart.start();
}, false);