mirror of
https://github.com/System-End/site.git
synced 2026-04-19 22:05:11 +00:00
page
This commit is contained in:
parent
82958c4379
commit
e3b2cdef3a
1 changed files with 8 additions and 8 deletions
|
|
@ -33,11 +33,11 @@ export default function Page({ projects, itemCount, currentPage }) {
|
|||
// }
|
||||
// }
|
||||
|
||||
export async function getStaticPaths(_context) {
|
||||
const projectCount = await onboardProjectCount()
|
||||
const pages = Math.min(5, Math.ceil(projectCount / 10))
|
||||
const paths = Array(pages)
|
||||
.fill()
|
||||
.map((_, i) => ({ params: { page: (i + 1).toString() } }))
|
||||
return { paths, fallback: 'blocking' }
|
||||
}
|
||||
// export async function getStaticPaths(_context) {
|
||||
// const projectCount = await onboardProjectCount()
|
||||
// const pages = Math.min(5, Math.ceil(projectCount / 10))
|
||||
// const paths = Array(pages)
|
||||
// .fill()
|
||||
// .map((_, i) => ({ params: { page: (i + 1).toString() } }))
|
||||
// return { paths, fallback: 'blocking' }
|
||||
// }
|
||||
Loading…
Add table
Reference in a new issue