mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-05-16 15:09:28 +00:00
25 lines
512 B
JavaScript
25 lines
512 B
JavaScript
import { getGlobalNotionData } from '@/lib/notion/getNotionData'
|
|
import React from 'react'
|
|
import { LayoutArchive } from '@/themes'
|
|
|
|
export async function getStaticProps () {
|
|
const { allPosts, categories, tags, postCount } =
|
|
await getGlobalNotionData({ from: 'archive-index' })
|
|
|
|
return {
|
|
props: {
|
|
posts: allPosts,
|
|
tags,
|
|
categories,
|
|
postCount
|
|
},
|
|
revalidate: 1
|
|
}
|
|
}
|
|
|
|
const ArchiveIndex = (props) => {
|
|
return <LayoutArchive {...props}/>
|
|
}
|
|
|
|
export default ArchiveIndex
|