From 5153f72054e527cb6113e7cf4775c37a4dc4b139 Mon Sep 17 00:00:00 2001 From: goncy Date: Wed, 4 Sep 2024 14:23:51 -0300 Subject: [PATCH] Update generated paths --- src/app/[[...product]]/page.tsx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/app/[[...product]]/page.tsx b/src/app/[[...product]]/page.tsx index 3e00461..70f07af 100644 --- a/src/app/[[...product]]/page.tsx +++ b/src/app/[[...product]]/page.tsx @@ -6,14 +6,13 @@ import StoreScreen from "@/modules/store/screens/Store"; export const dynamic = "force-static"; +export const dynamicParams = false; + export async function generateStaticParams() { const products = await api.list(); // Build index for the home page and then for each product - return [{}].concat(products.map((product) => ({product: [product.id]}))) as Record< - string, - string[] - >[]; + return products.map((product) => ({product: [product.id]})).concat({product: []}); } export async function generateMetadata({