quill-mathlive-blot

A Blot/Extension for Quill.js to embed editable formulas with mathLive

Usage no npm install needed!

<script type="module">
  import quillMathliveBlot from 'https://cdn.skypack.dev/quill-mathlive-blot';
</script>

README

npm npm bundle size npm GitHub Workflow Status GitHub GitHub last commit Maintenance

Quill-mathLive-blot

A Blot/Extension for Quill.js to embed editable formulas with mathLive.

Installation:

npm install quill-mathlive-blot

Usage:

  • import Quill
import mathLiveBlot from "quill-mathlive-blot";

var quill = new Quill('#editor-container', {
    modules: {
      toolbar: [
        ['bold', 'italic', 'underline'],
      ]
    },
    placeholder: '',
    theme: 'snow'
});

mathLiveBlot.register(Quill);

function insert() {
    let selection = quill.getSelection();
    quill.insertEmbed(selection.index, "mathLive", "");
}

Live Demo