import { getWikiPageBySlug } from '@/lib/wiki'; import { notFound } from 'next/navigation'; import { MDXRemote } from 'next-mdx-remote/rsc'; import rehypePrettyCode from 'rehype-pretty-code'; import { Callout, Grid, Card, Steps, Step, InlineCode } from '@/components/mdx-components'; const mdxOptions = { mdxOptions: { rehypePlugins: [ [ rehypePrettyCode, { theme: 'github-dark', keepBackground: true, }, ], ], }, }; const mdxComponents = { // Eigene UI-Komponenten Callout, Grid, Card, Steps, Step, // Custom Typography Überschreibungen code: InlineCode, h1: (props: any) =>

, h2: (props: any) =>

, h3: (props: any) =>

, }; type PageProps = { params: Promise<{ slug: string; }>; }; export default async function Page({ params }: PageProps) { const { slug } = await params; const article = await getWikiPageBySlug(slug); if (!article) { notFound(); } return (

{article.title}

{article.updatedAt && (

Zuletzt aktualisiert: {article.updatedAt}

)}
); }