I get an error when trying to use the formula module in quill.
Error:
"[Parchment] Unable to create formula blot"
Following the error message in the Chrome website development tools, the following line is in registry.ts (webpack:///./~/parchment/src/registry.ts)
function create(input, value) { var match = query(input); if (match == null) { throw new ParchmentError("Unable to create " + input + " blot"); } var BlotClass = match; var node = input instanceof Node ? input : BlotClass.create(value); return new BlotClass(node, value); }
This happens when I try to insert a formula.
This happens when I use quill-rails5 , but also without using a gem. I removed the stone to simplify the problem. Here is my code:
var quill = new Quill('#editor', { modules: { formula: true, toolbar: [ [{ header: [1, 2, false] }], ['bold', 'italic', 'underline'], ['image', 'code-block'], ['formula'], ] }, placeholder: 'Compose a solution...', theme: 'snow' // or 'bubble' });
my editor container
<div id="editor"> <%= raw sanitize @post.description, tags: %w(strong em div ap br ul ol li), attributes: %w(href) %> </div>