Files
archicratie-edition/src/pages/glossaire/[...slug].astro

30 lines
689 B
Plaintext

---
import EditionLayout from "../../layouts/EditionLayout.astro";
import { getCollection } from "astro:content";
export async function getStaticPaths() {
const entries = await getCollection("glossaire");
return entries.map((entry) => ({
params: { slug: entry.slug },
props: { entry },
}));
}
const { entry } = Astro.props;
const { Content } = await entry.render();
---
<EditionLayout
title={entry.data.title}
editionLabel="Glossaire"
editionKey="glossaire"
statusLabel="référentiel"
statusKey="referentiel"
level={1}
version={entry.data.version}
>
<h1>{entry.data.term}</h1>
<p><em>{entry.data.definitionShort}</em></p>
<Content />
</EditionLayout>