wip: testing remark; trying to downgrade some libs

This commit is contained in:
2024-05-09 22:31:01 +10:00
parent cbcf6a731b
commit 0ca7a97d26
4 changed files with 48 additions and 6 deletions

View File

@@ -25,16 +25,14 @@ const options: HTMLReactParserOptions = {
export default async function Post({ params }: { params: { slug: string } }) {
let content;
const dummySlug = await DummyPostSlug();
const dummySlug = DummyPostSlug();
if (dummySlug === params.slug) {
content = await DummyPostString();
// console.log(content);
} else {
content = await getPost(params.slug);
}
content = DOMPurify(new JSDOM("<!DOCTYPE html>").window).sanitize(content);
// console.log(content)
const elem = parse(content, options);
return (