Store Locations in JavaScript

Using ApexCharts with JavaScript

This Store Locations example uses ApexCharts.js directly in JavaScript, with no wrapper component.

Install it with npm install apexcharts, then mount the chart with new ApexCharts(element, options).render().

JavaScript installation guide
var options = {
  series: [360, 840, 1280, 480],
  chart: {
    type: 'unit',
    height: 470,
    animations: {
      enabled: true,
      speed: 900,
    },
  },
  labels: ['Superstore', 'Supermarket', 'Convenience', 'Franchise'],
  colors: ['#1565C0', '#00A6A0', '#F2994A', '#7B8794'],
  plotOptions: {
    unit: {
      layout: 'custom',
      // One of the shapes in apexcharts/unit-shapes.
      positions: 'pin',
      transition: 'flow',
      unitValue: 2,
      clusterLabels: {
        show: false,
      },
    },
  },
  legend: {
    position: 'bottom',
  },
}

var chart = new ApexCharts(document.querySelector('#chart'), options)
chart.render()