Skip to content

Commit

Permalink
[examples] Adjust custom page
Browse files Browse the repository at this point in the history
  • Loading branch information
Xennis committed May 30, 2024
1 parent f729c40 commit cc926b2
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions examples/nextjs/src/app/custom/page.tsx
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
import { Render } from "@react-notion-cms/render"
import { getCachedPageContent } from "@/lib/fetchers"

const demoLocale = "en_US"
const demoLocales = "de"
const demoPage = "af2bbd48-fce9-471c-8c3c-21f2ac376e74"

const formatDateFn = (date: Date) => {
return date.toLocaleDateString(demoLocale, {
month: "short",
return date.toLocaleDateString(demoLocales, {
month: "long",
day: "numeric",
year: "numeric",
})
}

export default async function CustomPage() {
const blocks = await getCachedPageContent(process.env.NOTION_BLOCK_ID!)
const blocks = await getCachedPageContent(demoPage)

return (
<Render
Expand Down

0 comments on commit cc926b2

Please sign in to comment.