Skip to main content
Version: Next

Content tools

Five packages that work on the content itself rather than on the editor. Each one has no runtime dependencies, runs with Editora or any other editor (Tiptap, Lexical, ProseMirror, Quill, a plain contenteditable), and most also run on a server.

PackageWhat it doesWhere it runs
@editora/paste-cleanerTurns pastes from Word, Google Docs, Sheets, Excel, Pages and web pages into clean HTML with real lists, headings and tables; Markdown pastes get structure tooEditor plugin, any contenteditable, Tiptap/ProseMirror hooks, server
@editora/content-a11yChecks what authors write (alt text, headings, link text, tables, contrast...) against WCAG 2.2 and offers fixesEditor plugin, any contenteditable, server, CLI for CI
@editora/ai-reviewShows an AI rewrite as word-level suggestions the user accepts or rejects, like tracked changesEditor plugin, any contenteditable, headless, server proxy
@editora/email-htmlTurns editor HTML into email-safe HTML for Outlook, Gmail and Apple Mail, plus a plain-text versionNode, browser, CLI
@editora/rich-text-convertConverts between Tiptap/ProseMirror JSON, Lexical, Slate, Plate, Portable Text, Editor.js, HTML and Markdown, and reports what could not be carried overNode, browser, CLI

Using them together in Editora​

The first three are Editora plugins:

npm i @editora/core @editora/paste-cleaner @editora/content-a11y @editora/ai-review
import '@editora/core/webcomponent';
import '@editora/core/webcomponent.css';
import { PasteCleanerPlugin } from '@editora/paste-cleaner/editora';
import { ContentA11yPlugin } from '@editora/content-a11y/editora';
import { AIReviewPlugin } from '@editora/ai-review/editora';

const editor = document.querySelector('editora-editor');
editor.setConfig({
plugins: [
'heading', 'bold', 'italic', 'link', 'list', 'table', 'history',
PasteCleanerPlugin(),
ContentA11yPlugin({ minHeadingLevel: 2 }),
AIReviewPlugin(),
],
toolbar: 'undo redo | heading bold italic link | bullist table | openAIReview toggleContentA11y',
});

The other two work on the HTML you get out of the editor:

import { toEmailHtml } from '@editora/email-html';
import { convert } from '@editora/rich-text-convert';

const html = editor.getContent();
const email = toEmailHtml(html, { title: 'Weekly update' }); // { html, text, warnings }
const { output: markdown } = convert(html, { from: 'html', to: 'markdown' });