Skip to content
On this page

MarkdownEditor

Draft
Full-featured Markdown input.
On this page
import {MarkdownEditor} from '@primer/react/drafts'

MarkdownEditor is a full-featured editor for GitHub Flavored Markdown, with support for:

  • Formatting (keyboard shortcuts & toolbar buttons)
  • File uploads (drag & drop, paste, click to upload)
  • Inline suggestions (emojis, @ mentions, and # references)
  • Saved replies
  • Markdown pasting (ie, paste URL onto selected text to create a link)
  • List editing (create a new list item on Enter)
  • Indenting selected text

Examples

Minimal Example

A Label is always required for accessibility:

Suggestions, File Uploads, and Saved Replies

Custom Buttons