commerce/app/search/[collection]/opengraph-image.tsx
2025-03-14 00:36:51 -04:00

14 lines
358 B
TypeScript

import OpengraphImage from "components/opengraph-image";
import { getCollection } from "lib/sfcc";
export default async function Image({
params
}: {
params: { collection: string };
}) {
const collection = await getCollection(params.collection);
const title = collection?.seo?.title || collection?.title;
return await OpengraphImage({ title });
}