site: change md export

This commit is contained in:
Glen Huang
2025-10-07 08:29:36 +08:00
committed by Johannes Kirschbauer
parent a40c6884d9
commit db98d106a1
2 changed files with 4 additions and 8 deletions

View File

@@ -1,7 +1,7 @@
import { error } from "@sveltejs/kit";
const articles = import.meta.glob<{
default: string;
content: string;
frontmatter: {};
toc: {};
}>("../**/*.md");
@@ -12,10 +12,6 @@ export async function load({ params }) {
error(404, "");
}
const { frontmatter, toc, default: content } = await article();
return {
content,
frontmatter,
toc,
};
const { frontmatter, toc, content } = await article();
return { frontmatter, toc, content };
}