@nebula.js/sn-action-button

Action button supernova for nebula.js

Usage no npm install needed!

<script type="module">
  import nebulaJsSnActionButton from 'https://cdn.skypack.dev/@nebula.js/sn-action-button';
</script>

README

sn-action-button

Action button supernova for nebula.js

CircleCI Coverage Status

Action button preview

Installing

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

Usage

import { embed } from '@nebula.js/stardust';
import actionButton from '@nebula.js/sn-action-button';

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

nuked.render({
  element,
  type: 'action-button',
});

See full example