From 8126a1fd21d8ff79f177f614192a204444db3c20 Mon Sep 17 00:00:00 2001 From: Samantha Kellow Date: Thu, 23 Nov 2023 19:16:51 +0000 Subject: [PATCH] removing unecessary oaesg --- app/wall/[handle]/page.tsx | 145 ----------------------------- app/wall/[handle]/sku/page.tsx | 55 ----------- app/wardrobe/[handle]/page.tsx | 145 ----------------------------- app/wardrobe/[handle]/sku/page.tsx | 55 ----------- 4 files changed, 400 deletions(-) delete mode 100644 app/wall/[handle]/page.tsx delete mode 100644 app/wall/[handle]/sku/page.tsx delete mode 100644 app/wardrobe/[handle]/page.tsx delete mode 100644 app/wardrobe/[handle]/sku/page.tsx diff --git a/app/wall/[handle]/page.tsx b/app/wall/[handle]/page.tsx deleted file mode 100644 index bc77f93dd..000000000 --- a/app/wall/[handle]/page.tsx +++ /dev/null @@ -1,145 +0,0 @@ -import type { Metadata } from 'next'; -import { notFound } from 'next/navigation'; -import { Suspense } from 'react'; - -import { GridTileImage } from 'components/grid/tile'; -import Footer from 'components/layout/footer'; -import { Gallery } from 'components/product/gallery'; -import { ProductDescription } from 'components/product/product-description'; -import { HIDDEN_PRODUCT_TAG } from 'lib/constants'; -import { getProduct, getProductRecommendations } from 'lib/shopify'; -import { Image } from 'lib/shopify/types'; -import Link from 'next/link'; - -export const runtime = 'edge'; - -export async function generateMetadata({ - params -}: { - params: { handle: string }; -}): Promise { - const product = await getProduct(params.handle); - - if (!product) return notFound(); - - const { url, width, height, altText: alt } = product.featuredImage || {}; - const hide = !product.tags.includes(HIDDEN_PRODUCT_TAG); - - return { - title: product.seo.title || product.title, - description: product.seo.description || product.description, - robots: { - index: hide, - follow: hide, - googleBot: { - index: hide, - follow: hide - } - }, - openGraph: url - ? { - images: [ - { - url, - width, - height, - alt - } - ] - } - : null - }; -} - -export default async function ProductPage({ params }: { params: { handle: string } }) { - const product = await getProduct(params.handle); - - if (!product) return notFound(); - - const productJsonLd = { - '@context': 'https://schema.org', - '@type': 'Product', - name: product.title, - description: product.description, - image: product.featuredImage.url, - offers: { - '@type': 'AggregateOffer', - availability: product.availableForSale - ? 'https://schema.org/InStock' - : 'https://schema.org/OutOfStock', - priceCurrency: product.priceRange.minVariantPrice.currencyCode, - highPrice: product.priceRange.maxVariantPrice.amount, - lowPrice: product.priceRange.minVariantPrice.amount - } - }; - - return ( - <> -