quickshell-web/src/pages/docs/guide/[...id].astro
2025-06-08 01:53:24 -07:00

20 lines
515 B
Text

---
import GuideLayout from "@layouts/GuideLayout.astro";
import { getCollection, render } from "astro:content";
export async function getStaticPaths() {
const guidePages = await getCollection("guide");
return guidePages.map(page => ({
params: { id: page.id == "index" ? "/" : page.id },
props: { page },
}));
}
const { page } = Astro.props;
const { Content, headings } = await render(page);
---
<GuideLayout title={page.data.title} description="" headings={headings}>
<Content/>
</GuideLayout>