[taskboard] migrate fleet console to nextjs
This commit is contained in:
23
app/wiki/page.tsx
Normal file
23
app/wiki/page.tsx
Normal file
@@ -0,0 +1,23 @@
|
||||
import { WikiView } from "@/components/wiki-view";
|
||||
import { listWikiPages, readWikiPage } from "@/lib/wiki";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
export default async function WikiPage() {
|
||||
const pages = listWikiPages();
|
||||
const firstPage = pages[0] ? readWikiPage(pages[0].filename) : null;
|
||||
|
||||
return (
|
||||
<WikiView
|
||||
pages={pages}
|
||||
initialPageContent={
|
||||
firstPage
|
||||
? {
|
||||
title: firstPage.metadata.title,
|
||||
content: firstPage.content,
|
||||
}
|
||||
: null
|
||||
}
|
||||
/>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user