Skip to content

Commit

Permalink
fix: Temporarily turn off generateStaticParams() in slug routes
Browse files Browse the repository at this point in the history
  • Loading branch information
codinsonn committed Oct 26, 2023
1 parent 5c23f66 commit e955900
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions features/cv-page/screens/ResumeScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -269,9 +269,11 @@ export const ResumeScreenRouteDataConfig = {
// -i- https://nextjs.org/docs/app/api-reference/file-conventions/route-segment-config
export const dynamic = 'force-static' // 'auto' | 'force-dynamic' | 'error' | 'force-static'

export const generateStaticParams = async (): Promise<TResumeScreenParams[]> => {
return [{ slug: 'codinsonn' }]
}
// TODO: Figure out how to generate static params in Next.js 14 while also needing to use client components
// -!- Error: Page "/(generated)/bio/[slug]/page" cannot use both "use client" and export function "generateStaticParams()".
// export const generateStaticParams = async (): Promise<TResumeScreenParams[]> => {
// return [{ slug: 'codinsonn' }]
// }

/* --- <ResumeScreen/> ------------------------------------------------------------------------- */

Expand Down

0 comments on commit e955900

Please sign in to comment.