Custom Quill Integration for CMS: Delta, Image Upload & Modules

In a Next.js 14 project, we needed a rich-text editor for a CMS admin panel handling up to 5000 records. The standard Quill 2.x didn't fit: its toolbar couldn't upload images to the server, and table formatting was missing—we'd have to store base64 strings, inflating document size by 30–50%. The bui

Development and maintenance of all types of websites:

Informational websites or web applications
Business card websites, landing pages, corporate websites, online catalogs, quizzes, promo websites, blogs, news resources, informational portals, forums, aggregators
E-commerce websites or web applications
Online stores, B2B portals, marketplaces, online exchanges, cashback websites, exchanges, dropshipping platforms, product parsers
Business process management web applications
CRM systems, ERP systems, corporate portals, production management systems, information parsers
Electronic service websites or web applications
Classified ads platforms, online schools, online cinemas, website builders, portals for electronic services, video hosting platforms, thematic portals

These are just some of the technical types of websites we work with, and each of them can have its own specific features and functionality, as well as be customized to meet the specific needs and goals of the client.

Our competencies:

Frequently Asked Questions

Latest works

  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1281
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1237
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    977
  • image_crm_chasseurs_493_0.webp
    CRM development for Chasseurs
    1025
  • image_website-sbh_0.webp
    Website development for SBH Partners
    1103
  • image_website-_0.webp
    Website development for Red Pear
    550

In a Next.js 14 project, we needed a rich-text editor for a CMS admin panel handling up to 5000 records. The standard Quill 2.x didn't fit: its toolbar couldn't upload images to the server, and table formatting was missing—we'd have to store base64 strings, inflating document size by 30–50%. The built-in modules provided only basic features, but a real product required custom handlers and Delta format support. We developed custom modules that integrate with React and Vue. Let me walk you through the challenges we encountered and how we solved them.

Why Basic Quill Doesn't Suit CMS

A typical Quill setup gives basic functionality, but in production you run into issues:

  • Image upload. By default, Quill embeds images as base64, bloating JSON by 30–50%. We write a custom handler that uploads the file to the server and inserts the URL. This reduces database load and speeds up page loading.
  • Custom modules: tables, nested lists, text color. Quill is extendable via third-party plugins, but they aren't always stable. For one project, we had to write a module for nested lists because the ready-made one didn't support depths beyond 2 levels.
  • Saving in Delta vs HTML. Delta is convenient for versioning and collaborative editing, but HTML is often needed for output. We provide both by converting Delta to HTML using quill-delta-to-html.
Problem Solution Implementation Time Savings vs Commercial Editor
base64 images custom handler with server upload 2–4 hours significant cost reduction
missing tables plugin quill-better-table 1–2 hours
complex customization creating own module based on Quill API from 1 day substantial license savings

How We Integrate Quill with Custom Modules

Our process includes:

  1. Analyze editor requirements: buttons, formats, media upload, mobile support.
  2. Design modules: custom handlers, theme (snow/bubble or custom), toolbar configuration.
  3. Implementation: code in React (react-quill-new), Vue, or vanilla JS. Example custom image handler:
const imageHandler = () => { const input = document.createElement('input'); input.setAttribute('type', 'file'); input.setAttribute('accept', 'image/*'); input.click(); input.onchange = async () => { const file = input.files[0]; const formData = new FormData(); formData.append('image', file); const response = await fetch('/api/media/upload', { method: 'POST', body: formData }); const { url } = await response.json(); const quill = quillRef.current.getEditor(); const range = quill.getSelection(true); quill.insertEmbed(range.index, 'image', url); }; }; const MODULES = { toolbar: { container: [...], handlers: { image: imageHandler } } }; 
  1. Test on all devices and browsers (Chrome, Firefox, Safari, Edge). Verify SSR correctness, image upload, Delta->HTML conversion.
  2. Deploy and document. We deliver source code, setup instructions, and three months of support.

What Delta Format Offers

Delta is an array of operations (insert, delete, retain) that is easy to store, transmit, and transform. Unlike HTML, Delta preserves formatting semantics: each style is stored as an operation attribute. This enables undo/redo at any step, collaborative editing via OT algorithms, and automatic merge of changes. As described in the Delta format documentation, a Delta object is typically 40% smaller than equivalent HTML for the same content. If your project requires versioning, Delta is the right choice.

Comparison with Alternatives

Criterion Quill 2.x TinyMCE 6 CKEditor 5
Bundle size (min+gzip) ~40 KB ~200 KB ~300 KB
Data format Delta (JSON) HTML HTML/JSON
Customization Medium (module API) High (plugins) High (UI)
Tables Plugin Built-in Built-in
Annual license (USD) 0 (open source) from ~$1,200 from ~$1,800

Quill wins on load speed and simplicity. If you don't need complex nested blocks, it's the best choice. If unsure, contact us for a free consultation.

How to Avoid Common Integration Mistakes

  • Forgetting to disable SSR for Quill in Next.js gives document is not defined. Use dynamic import with ssr: false.
  • Using outdated react-quill instead of react-quill-new (the latter supports React 18 and SSR correctly).
  • Not wrapping handlers in useCallback—infinite re-renders.
  • Confusing Delta and HTML: inserting HTML via setContents loses formatting. Use clipboard.dangerouslyPasteHTML or conversion.

What's Included in the Integration Work

  • Requirements analysis and stack choice (React, Vue, or Next.js)
  • Toolbar, modules, theme configuration
  • Custom image upload handler
  • Export to HTML and/or Delta
  • Hook integration (onChange, onBlur, validation)
  • Documentation and team training
  • Code warranty (3 months free support)

Timeline and Cost

Integration of Quill with custom modules takes 1 to 3 days depending on complexity. The cost is calculated individually after brief. On average, such integration is 30–50% cheaper than licensing commercial editors. Get a free engineer consultation—contact us to evaluate your project.