Astro · Routing and content

Render a Markdown entry

Render the Markdown body of a collection entry.

---
import { getEntry, render } from "astro:content";
const post = await getEntry("blog", "first-post");
const { Content } = await render(post);
---
<Content />

Official Astro documentation

More routing and content commands

All routing and content commands · Astro cheatsheet

Was this page helpful?