JSFiddle - React, Tailwind, and code Playground

by anikettiwari

HTML

<script src="https://code.highcharts.com/7.0.1/highcharts.js"></script>

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

<div id="container"></div>

CSS

#container {
  min-width: 300px;
  max-width: 800px;
  height: 300px;
  margin: 1em auto;
}

JavaScript

const options = {
  chart: {
    type: 'pie',
    height: 340,
  },
  title: {
    text: ''
  },
  plotOptions: {
    series: {
      dataLabels: {
        enabled: true,
				padding: 0
      },
    },
    pie: {
      startAngle: 0,
      endAngle: 180,
      center: [0, 125],
    }
  },
  series: [{
    innerSize: 155,
    size: 205,
    distance: 30,
    data: [85, 5, 1, 1, 2, 1, 1],
  }, {
    innerSize: 105,
    size: 155,
    data: [87, 2],
    dataLabels: {
      enabled: false
    }
  }],
}

const chart = Highcharts.chart('container', options);