hotfix: errors

This commit is contained in:
Harivansh Rathi 2025-02-20 20:01:54 -05:00
parent 4e59c6866d
commit cbcb3aa87e
3 changed files with 55 additions and 55 deletions

View file

@ -1,58 +1,58 @@
import { ShopifyProduct } from '../types/shopify'; import { ShopifyProduct } from '../types/shopify';
export const mockProducts: ShopifyProduct[] = [ export const mockProducts: ShopifyProduct[] = [
{ {
id: '1', id: '1',
title: 'Whey Protein Isolate', title: 'Whey Protein Isolate',
description: 'Premium whey protein isolate for optimal muscle recovery and growth.', description: 'Premium whey protein isolate for optimal muscle recovery and growth.',
handle: 'whey-protein-isolate', handle: 'whey-protein-isolate',
priceRange: { priceRange: {
minVariantPrice: { minVariantPrice: {
amount: '49.99', amount: '49.99',
currencyCode: 'USD' currencyCode: 'USD'
} }
},
featuredImage: {
url: 'https://images.unsplash.com/photo-1593095948071-474c5cc2989d?q=80&w=2670&auto=format&fit=crop',
altText: 'Whey Protein Container',
width: 800,
height: 800
}
}, },
featuredImage: { {
url: 'https://images.unsplash.com/photo-1593095948071-474c5cc2989d?q=80&w=2670&auto=format&fit=crop', id: '2',
altText: 'Whey Protein Container', title: 'Pre-Workout Energy',
width: 800, description: 'Advanced pre-workout formula for enhanced performance and focus.',
height: 800 handle: 'pre-workout-energy',
} priceRange: {
}, minVariantPrice: {
{ amount: '39.99',
id: '2', currencyCode: 'USD'
title: 'Pre-Workout Energy', }
description: 'Advanced pre-workout formula for enhanced performance and focus.', },
handle: 'pre-workout-energy', featuredImage: {
priceRange: { url: 'https://images.unsplash.com/photo-1594882645126-14020914d58d?q=80&w=2785&auto=format&fit=crop',
minVariantPrice: { altText: 'Pre-workout Container',
amount: '39.99', width: 800,
currencyCode: 'USD' height: 800
} }
}, },
featuredImage: { {
url: 'https://images.unsplash.com/photo-1594882645126-14020914d58d?q=80&w=2785&auto=format&fit=crop', id: '3',
altText: 'Pre-workout Container', title: 'BCAA Complex',
width: 800, description: 'Essential branched-chain amino acids for muscle support and recovery.',
height: 800 handle: 'bcaa-complex',
priceRange: {
minVariantPrice: {
amount: '29.99',
currencyCode: 'USD'
}
},
featuredImage: {
url: 'https://images.unsplash.com/photo-1579722820308-d74e571900a9?q=80&w=2670&auto=format&fit=crop',
altText: 'BCAA Container',
width: 800,
height: 800
}
} }
},
{
id: '3',
title: 'BCAA Complex',
description: 'Essential branched-chain amino acids for muscle support and recovery.',
handle: 'bcaa-complex',
priceRange: {
minVariantPrice: {
amount: '29.99',
currencyCode: 'USD'
}
},
featuredImage: {
url: 'https://images.unsplash.com/photo-1579722820308-d74e571900a9?q=80&w=2670&auto=format&fit=crop',
altText: 'BCAA Container',
width: 800,
height: 800
}
}
]; ];

6
src/env.d.ts vendored
View file

@ -1,10 +1,10 @@
/// <reference types="vite/client" /> /// <reference types="vite/client" />
interface ImportMetaEnv { interface ImportMetaEnv {
readonly VITE_SHOPIFY_STORE_DOMAIN: string; readonly VITE_SHOPIFY_STORE_DOMAIN: string;
readonly VITE_SHOPIFY_STOREFRONT_TOKEN: string; readonly VITE_SHOPIFY_STOREFRONT_TOKEN: string;
} }
interface ImportMeta { interface ImportMeta {
readonly env: ImportMetaEnv; readonly env: ImportMetaEnv;
} }

View file

@ -3,5 +3,5 @@ import { ShopifyProductGrid } from '../components/ShopifyProductGrid';
import { mockProducts } from '../data/mockShopifyProducts'; import { mockProducts } from '../data/mockShopifyProducts';
export const ProductsPage: React.FC = () => { export const ProductsPage: React.FC = () => {
return <ShopifyProductGrid products={mockProducts} />; return <ShopifyProductGrid products={mockProducts} />;
}; };