docs: update as per docs

This commit is contained in:
rzmk 2026-06-11 18:11:00 -04:00
parent b745dffeda
commit f3aa0c4e21

View file

@ -1,8 +1,9 @@
import type { InferPageType } from "fumadocs-core/source";
import type { source } from "@/lib/source"; import type { source } from "@/lib/source";
export async function getLLMText(page: InferPageType<typeof source>) { export async function getLLMText(page: (typeof source)['$inferPage']) {
const processed = await page.data.getText("processed"); if (page.type === 'openapi') return JSON.stringify(page.data.getSchema(), null, 2);
const processed = await page.data.getText('processed');
return `# ${page.data.title} (${page.url}) return `# ${page.data.title} (${page.url})