Astro · Components and layouts

Use a layout in a page

Wrap page content in your layout component.

---
import Layout from "../layouts/Layout.astro";
---
<Layout title="Home">
  <h1>Welcome</h1>
</Layout>

Official Astro documentation

More components and layouts commands

All components and layouts commands · Astro cheatsheet

Was this page helpful?