This commit is contained in:
belle 2024-06-14 09:02:00 -04:00 committed by Max Wofford
parent a8bd1f6221
commit 30b1cfaeda

View file

@ -32,11 +32,11 @@ export async function getStaticProps(context) {
}
}
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' }
// }