We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8f04f49 commit 09c1399Copy full SHA for 09c1399
src/app/(home)/blog/[slug]/page.tsx
@@ -1,3 +1,4 @@
1
+import { lastEdit } from "@/lib/api"
2
import { blog } from "@/lib/source"
3
import { getMDXComponents } from "@/mdx-components"
4
import { PathUtils } from "fumadocs-core/source"
@@ -27,7 +28,7 @@ export default async function Page(props: PageProps<"/blog/[slug]">) {
27
28
<p className="text-xs uppercase tracking-wide text-neutral-500">Published</p>
29
<p className="font-medium">
30
{new Date(
- page.data.date ?? PathUtils.basename(page.path, PathUtils.extname(page.path)),
31
+ await lastEdit(page) ?? PathUtils.basename(page.path, PathUtils.extname(page.path)),
32
).toLocaleDateString("en-US", { month: "short", day: "numeric", year: "numeric" })}
33
</p>
34
</div>
0 commit comments