mirror of
https://github.com/vercel/commerce.git
synced 2025-07-23 04:36:49 +00:00
feat: homepage and integrate with shopify page
Signed-off-by: Chloe <pinkcloudvnn@gmail.com>
This commit is contained in:
@@ -380,12 +380,19 @@ export async function getCart(cartId: string): Promise<Cart | undefined> {
|
||||
return reshapeCart(res.body.data.cart);
|
||||
}
|
||||
|
||||
export async function getCollection(handle: string): Promise<Collection | undefined> {
|
||||
export async function getCollection({
|
||||
handle,
|
||||
id
|
||||
}: {
|
||||
handle?: string;
|
||||
id?: string;
|
||||
}): Promise<Collection | undefined> {
|
||||
const res = await shopifyFetch<ShopifyCollectionOperation>({
|
||||
query: getCollectionQuery,
|
||||
tags: [TAGS.collections],
|
||||
variables: {
|
||||
handle
|
||||
handle,
|
||||
id
|
||||
}
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user