Skip to content
Forms

Rich Text Editor

Tiptap WYSIWYG editor with a formatting toolbar and HTML output.

Import

tsx
import { RichTextEditor } from "@cooud-ui/ui";
bash
npx cooud-ui add rich-text-editor

Examples

API Reference

Generated from the component's exported types.

RichTextEditorProps

PropTypeDefaultDescription
value
stringControlled HTML value. When provided, external changes are synced into the editor.
defaultValue
stringUncontrolled initial HTML content. Ignored once the editor has mounted.
onChange
(html: string) => voidCalled with the serialized HTML whenever the document changes.
placeholder
stringPlaceholder shown while the document is empty.
editable
booleantrueWhether the content is editable. Defaults to `true`.
className
stringExtra classes for the editor shell (toolbar + content wrapper).
aria-label
stringAccessible label for the editable region.