@nebula.js/sn-mekko-chart

Compare the share of values using variable width of stacked bars

Usage no npm install needed!

<script type="module">
  import nebulaJsSnMekkoChart from 'https://cdn.skypack.dev/@nebula.js/sn-mekko-chart';
</script>

README

sn-mekko-chart

CircleCI Coverage Status

A basic mekko chart supernova aimed to be used in nebula.js.

mekko chart preview

Installing

If you use npm: npm install @nebula.js/sn-mekko-chart. You can also load through the script tag directly from https://unpkg.com.

Usage


import { embed } from '@nebula.js/stardust';
import mekko from '@nebula.js/sn-mekko-chart';

// 'app' is an enigma app model
const nuked = embed(app, {
  types: [{ // register the mekko chart
    name: 'mekko',
    load: () => Promise.resolve(mekko);
  }]
});

embed.render({
  element,
  type: 'mekko',
});

See full example