Docs
Components
Markdown

Markdown

Use the power of MDX to author your emails

⚠️

Note: There is no support for Context when using React Server Components. Please use the MDX import directly in combination with the function getMDXComponents

Basic Usage

Installation

If you haven't installed MailingUI in your project, please go through the Installation docs first.

npx @mailingui/cli add markdown
  • -p, --path define base path to your MailingUI components (default: "./src/mailingui")
  • -o, --overwrite overwrite existing configuration (default: false)
  • -h, `--help`` display help for command

Examples

Custom Styles

Newsletter

Usage with React Server Components

ℹ️

Note: The Markdown component allows us to nest multiple MDX files within one another and preserve their styles. There is currently no workaround when using RSC for this, however using the MDX import directly in combination with the function getMDXComponents works the same with the tradeoff of losing the ability to nest multiple files.