Back to blog
Ibrahima GUEYE

Writing posts with MDX

A short demo of what MDX unlocks — importing components directly into your Markdown and mixing JavaScript expressions with prose.

meta mdx

Regular Markdown still works exactly the same — headings, bold, italics, inline code, lists, tables, all of it.

The difference is that now you can reach for components when plain Markdown isn’t expressive enough.

Components inline

Callouts have three variants out of the box: info, warning, and success.

JavaScript expressions

You can embed expressions with curly braces: 4 equals four, and today is April 23, 2026.

When to use MDX vs plain Markdown

  • .md — prose-only posts: announcements, write-ups, notes. Keep it simple.
  • .mdx — posts where a component makes the idea clearer than words: embedded demos, callouts, custom figures, interactive widgets.

Both formats use the same layout: frontmatter and land in the same blog listing.