Motivation. Why Yoopta?
Beta Yoopta is fully open source and built with all my heart and love. It was born from real pain I’ve integrated rich-text editors into products more times than I’d like to admit. Every time it was the same story: wrestling with complex APIs, fighting against opinionated UI that doesn’t fit your product, hacking around limitations. Yoopta was built to end that cycle. The idea is simple: give developers a headless core when they need full control, but also ship 20+ ready-made plugins, pre-built UI components (toolbars, slash menus, block actions), and theme presets (shadcn, Material) — so you can launch a polished editing experience without thinking about implementing a rich-text editor in your project and engage in other business tasks. If Yoopta saves you time, consider starring the repo or sponsoring the project. It keeps the project alive.Architecture Overview
Headless Core
Yoopta Editor is headless by design. The core package (@yoopta/editor) provides all the logic for managing content, blocks, elements, and operations, but doesn’t render any UI. This means:
- You have complete control over the visual appearance
- You can build custom UI components that fit your design system
- The editor logic is framework-agnostic (though currently React-only)
- But (!!!) Yoopta also provides pre-built theme presets for each plugin so you can get a full editing experience and start quickly (shadcn theme is available now; Material theme is in progress)
- Yoopta also provides pre-built UI components via
@yoopta/ui(toolbars, menus, block actions etc.) so you can improve the editing experience without building everything from scratch
Themes
Themes provide pre-styled element components that make it easy to get started:@yoopta/themes-shadcn- Shadcn UI styled components (production ready)@yoopta/themes-material- Material Design styled components (in development)
applyTheme() to automatically apply styled components to your plugins.
UI Components Package
The@yoopta/ui package provides ready-to-use React components for common editor features:
- Toolbar - Text formatting toolbar
- ActionMenuList - Block insertion menu (slash command menu)
- SlashCommandMenu - Inline command menu
- BlockOptions - Block-level action menu
- FloatingBlockActions - Floating action buttons
- HighlightColorPicker - Color picker for text highlighting
- Portal & Overlay - Utility components for rendering outside DOM
Package Structure
Yoopta Editor is organized into several package categories:Core Packages
@yoopta/editor
The core headless editor package. Contains all the logic for:
- Block management
- Element tree structures
- Slate.js integration (one Slate editor per block)
- Content operations (insert, delete, update, etc.)
- History/undo-redo
- Parsers (HTML, Markdown, Email, Plain Text)
@yoopta/ui
Reusable UI components (toolbars, menus, block actions) that improve the editing experience
Installation:
Toolbar- Text formatting toolbarActionMenuList- Block insertion menuSlashCommandMenu- Inline slash command menuBlockOptions- Block action menuFloatingBlockActions- Floating action buttonsHighlightColorPicker- Color picker componentPortal&Overlay- Utility components
Plugin Packages
Plugins define block types and their behavior. Each plugin represents a type of content block.Text Plugins
@yoopta/paragraph- Basic paragraph block@yoopta/headings- Heading blocks (H1, H2, H3)@yoopta/blockquote- Blockquote block
List Plugins
@yoopta/lists- Bulleted lists, numbered lists, todo lists
Media Plugins
@yoopta/image- Image block with upload support@yoopta/video- Video embed block@yoopta/file- File attachment block@yoopta/embed- Generic embed block (YouTube, Twitter, etc.)
Layout Plugins
@yoopta/table- Table block with cell editing@yoopta/accordion- Collapsible accordion block@yoopta/divider- Horizontal divider@yoopta/callout- Callout/alert block@yoopta/tabs- Tabs block@yoopta/steps- Step-by-step guide block@yoopta/carousel- Image carousel block
Code Plugin
@yoopta/code- Code block with syntax highlighting
Link Plugin
@yoopta/link- Inline link element
Inline Plugins
@yoopta/mention- Mention users, channels, or custom resources with@trigger and autocomplete@yoopta/emoji- Insert emoji by typing:shortcodes with autocomplete dropdown
UI Components Package
The@yoopta/ui package provides all UI components for editor interactions. No separate tool packages needed.
Installation:
Toolbar- Text formatting toolbarActionMenuList- Block insertion menu (slash command menu)SlashCommandMenu- Inline slash command menuBlockOptions- Block-level action menuFloatingBlockActions- Floating action buttonsHighlightColorPicker- Color picker for text highlightingPortal&Overlay- Utility components for rendering outside DOM
Marks Package
Marks provide text formatting capabilities:Bold,Italic,Underline,StrikeCode- Inline code formattingHighlight- Text highlighting with colors and gradients
Theme Packages
@yoopta/themes-shadcn
Pre-styled components using Shadcn UI design system. Production ready.
@yoopta/themes-material
Material Design styled components (in development, coming soon).
Utility Packages
@yoopta/exports
Export editor content to various formats:
- Markdown
- HTML
- Plain Text
- Email (HTML email format)
Core Concepts
Slate Per Block
Yoopta Editor uses a unique architecture where each block has its own Slate.js editor instance. This means:- Each block is an independent Slate editor
- Blocks don’t share selection state
- Operations on one block don’t affect others
- Better performance for large documents
Block Structure
A block in Yoopta Editor consists of:- Block Data - Metadata and content
- Slate Value - The Slate.js document structure
- Element Tree - Hierarchical structure of elements
Element Tree
Each block contains a tree of elements. Elements can be:- Root Elements - Top-level element in a block
- Container Elements - Elements that contain other elements
- Leaf Elements - Elements that contain only text nodes
Editor Value Structure
The editor value (YooptaContentValue) is a record (object) where keys are block IDs and values are block data:
injectElementsFromPlugins
TheinjectElementsFromPlugins property allows elements from one plugin to be inserted inside elements of another plugin. This enables nested content structures.
Example - Callout with nested content:
callout element, the slash command menu will only show blocks from the injected plugins.
Use Cases:
- Callout blocks - Allow paragraphs, lists, and headings inside
- Table cells - Allow any block type inside cells
- Steps content - Allow nested content in step items
- Accordion items - Allow nested blocks inside accordion content
- Tab items - Allow nested blocks inside tab leaf elements
- When the cursor is inside an element with
injectElementsFromPlugins - The slash command menu filters available blocks to only those specified
- Inserted blocks become children of that element
Plugin System
Plugin Structure
A plugin defines:- Type - Unique identifier (e.g., ‘Paragraph’, ‘Table’)
- Elements - Element tree structure with render functions
- Commands - Custom operations for the plugin
- Options - Plugin-specific configuration
- Lifecycle - Hooks for plugin initialization
- Events - Keyboard and interaction handlers
- Extensions - Slate.js editor extensions
Element Definition
Elements define the structure and rendering:Key Features
Headless Architecture
Complete separation of logic and UI. Use the core editor with your own components or choose from
pre-built themes.
Slate Per Block
Each block has its own Slate.js editor instance for better performance and isolation.
Element Tree
Hierarchical element structures allow complex nested content like tables, steps, and accordions.
Plugin System
Extensible plugin architecture. Create custom plugins or extend existing ones.
Nested Content
injectElementsFromPlugins allows blocks from one plugin inside elements of another.
TypeScript First
Built with TypeScript for excellent type safety and developer experience.
Drag & Drop
Intuitive drag and drop support, including nested elements and block reordering.
Mobile Friendly
Works seamlessly on mobile devices with touch support and responsive design.
Why Choose Yoopta Editor?
🎨 Complete Customization
🎨 Complete Customization
Every aspect of the editor can be customized - from the UI to the behavior of each plugin.
Create your own plugins or extend existing ones. Use headless core with your own components
or apply ready-made themes.
🚀 Production Ready
🚀 Production Ready
Handles large documents efficiently with automatic lazy loading for media components and optimized
performance. Each block is isolated with its own Slate editor.
💪 Developer Experience
💪 Developer Experience
Built with TypeScript, providing excellent type safety and IDE support. Clear API and
comprehensive documentation. Headless architecture gives you full control.
🌐 Open Source
🌐 Open Source
Free and open source with MIT license. Active community and regular updates.
📦 Modular Architecture
📦 Modular Architecture
Install only what you need. Core editor, UI components, plugins, and themes are separate packages.
Mix and match to build your perfect editor.
Quick Example
Next Steps
Installation
Install Yoopta Editor and its dependencies
Getting Started
Build your first editor in 5 minutes
Core Concepts
Deep dive into editor architecture
API Reference
Complete API documentation
Community & Support
Join our community to get help, share your projects, and contribute:- Discord Community - Chat with the team and community
- GitHub Discussions - Ask questions and share ideas
- GitHub Issues - Report bugs or request features
- Twitter - Follow for updates and news
If you find Yoopta Editor useful, please give it a ⭐️ star on
GitHub!

