Svelte Quill

-
Pro Component

The Svelte Quill is a powerful rich text editor built for compatibility and extensibility.
Keep reading our Svelte Quill examples and learn how to use this plugin.


Initialization

JS

In order to use this plugin on your page you will need to include the following script in the “Optional JS” area from the page’s footer:

<script>

import Quill from "quill";
let quill = null;

onMount(() => {
  let container = document.getElementById("editorId");
  quill = new Quill(container, {
    theme: "snow",
    modules: {
      toolbar: document.getElementById('toolbarId')
    }
  });
});

</script>

<svelte:head>
  <link href="//cdn.quilljs.com/1.3.6/quill.snow.css" rel="stylesheet" />
</svelte:head>

Example

<script>
import HtmlEditor from "../../../components/Inputs/HtmlEditor.svelte";
</script>

<form>
  <HtmlEditor />
</form>