mirror of
https://github.com/vercel/commerce.git
synced 2025-07-25 11:11:24 +00:00
merge-ppr-branch-into-narai-commerce
This commit is contained in:
@@ -1,7 +1,3 @@
|
||||
import { Suspense } from 'react';
|
||||
|
||||
export const revalidate = 300; // 5 minutes in seconds
|
||||
|
||||
export default function Layout({ children }: { children: React.ReactNode }) {
|
||||
return <Suspense>{children}</Suspense>;
|
||||
return <>{children}</>;
|
||||
}
|
||||
|
@@ -1,9 +1,6 @@
|
||||
import OpengraphImage from 'components/opengraph-image';
|
||||
import { getPage } from 'lib/shopify';
|
||||
|
||||
export const runtime = 'edge';
|
||||
export const revalidate = 300; // 5 minutes in seconds
|
||||
|
||||
export default async function Image({ params }: { params: { page: string } }) {
|
||||
const page = await getPage({ handle: params.page });
|
||||
const title = page.seo?.title || page.title;
|
||||
|
@@ -8,11 +8,8 @@ import { getCart, getPage, getProduct } from 'lib/shopify';
|
||||
import { Product } from 'lib/shopify/types';
|
||||
import { cookies } from 'next/headers';
|
||||
import { notFound } from 'next/navigation';
|
||||
import { Suspense } from 'react';
|
||||
import ShopsNav from './shops-nav';
|
||||
|
||||
export const revalidate = 300; // 5 minutes in seconds
|
||||
|
||||
export async function generateMetadata({
|
||||
params
|
||||
}: {
|
||||
@@ -61,9 +58,7 @@ export default async function Page({ params }: { params: { locale?: SupportedLoc
|
||||
<Prose html={page.body as string} />
|
||||
</div>
|
||||
|
||||
<Suspense>
|
||||
<Footer cart={cart} />
|
||||
</Suspense>
|
||||
<Footer cart={cart} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user