initial commit

This commit is contained in:
Hunter
2026-11-01 13:23:44 -05:00
commit e03ea4f770
53 changed files with 10802 additions and 0 deletions

8
app/api/preview/route.ts Normal file
View File

@@ -0,0 +1,8 @@
import { readJson, route } from "@/lib/http";
import { renderMarkdown } from "@/lib/markdown";
/** Body: { markdown } -> { html }, rendered by the site's own pipeline. */
export const POST = route(async (req) => {
const { markdown } = await readJson<{ markdown?: string }>(req);
return Response.json({ html: await renderMarkdown(markdown ?? "") });
});