mirror of
https://github.com/dathere/ckanaction.git
synced 2025-12-26 12:57:00 +00:00
build: update dependencies and fumadocs
This commit is contained in:
parent
100165ec29
commit
fd5ebf4af0
144 changed files with 301 additions and 431 deletions
24
docs/app/llms.mdx/[[...slug]]/route.ts
Normal file
24
docs/app/llms.mdx/[[...slug]]/route.ts
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
import { notFound } from "next/navigation";
|
||||
import { getLLMText } from "@/lib/get-llm-text";
|
||||
import { source } from "@/lib/source";
|
||||
|
||||
export const revalidate = false;
|
||||
|
||||
export async function GET(
|
||||
_req: Request,
|
||||
{ params }: RouteContext<"/llms.mdx/[[...slug]]">,
|
||||
) {
|
||||
const { slug } = await params;
|
||||
const page = source.getPage(slug);
|
||||
if (!page) notFound();
|
||||
|
||||
return new Response(await getLLMText(page), {
|
||||
headers: {
|
||||
"Content-Type": "text/markdown",
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
export function generateStaticParams() {
|
||||
return source.generateParams();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue