useProductListItem
This hook is used to get the product list item data.
props | Type | Description | Example |
---|---|---|---|
thumbnail_meta | Object | Thumbnail meta | {altText: null, height: 1039, src: "https://cdn.shopify.com/s/files/1/0571/2193/1426/products/518s6Q_2BEqxL._AC_UX522.jpg?v=1622444565", url: "https://cdn.shopify.com/s/files/1/0571/2193/1426/products/518s6Q_2BEqxL._AC_UX522_500x500.jpg?v=1622444565", width: 522} |
wishList | Boolean | If product is in wishlist or not | true |
productType | String | Product type | normal |
firstAvailableVariant | Object | First available variant | |
product | Object | Product object | |
containerWidth | Number | Container width | 196.36363636363637 |
onQuantityChange | Function | Function to change quantity | |
addingTocartLoading | Boolean | add to cart loading | false |
openProduct | Function | Function to open product detail | |
onOpenProductDetail | Function | Function to open product detail | |
outOfStock | Boolean | If product is out of stock | false |
imageAspectRatio | Number | Image aspect ratio | 1 |
imageRatio | Number | Image ratio | 1 |
isProductListPage | Boolean | If product list page | true |
hasTag | Function | Function to check if product has tag | |
onSaved | Function | Function to save product | |
title | String | Product title | Appmaker Free gift |
imageUrl | String | Product image url | https://cdn.shopify.com/s/files/1/0571/2193/1426/products/gift-box-with-red-bow_120072-333_500x500.jpg?v=1664447615 |
salePercentage | string | Sale percentage | 20% |
salePrice | Number | Sale price | 20 |
regularPrice | Number | Regular price | 20 |
onAddToCart | Function | Function to add product to cart | |
isAddToCartLoading | Boolean | If add to cart loading | false |
average_rating | Number | Average rating | 4.5 |
reviews_count | Number | Reviews count | 2 |
gridViewListing | Boolean | If grid view listing | true |
addToCart | Function | Function to add product to cart | |
count | Number | Product count | 1 |
updateCart | Function | Function to update cart | |
adding | Boolean | If adding to cart | false |
setAdding | Function | Function to set adding to cart | |
show_last_few_remaining | Boolean | If show last few remaining | true |
show_last_few_remaining_text | String | Show last few remaining text | Only 2 left in stock |
brandColor | String | Brand color | #000000 |
numColumns | Number | Number of columns | 3 |
onSale | Boolean | If product is on sale | true |
tags | Array | Product tags | ["gift"] |
salePriceValue | Number | Sale price value | 20 |
regularPriceValue | Number | Regular price value | 20 |
hasReviews | Boolean | If product has reviews | true |
custom_fields | Array | Custom fields | [{key: "custom_field_1", value: "custom_field_1_value"}, {key: "custom_field_2", value: "custom_field_2_value"}] |
productNode | Object | Product node | |
isWishlistPage | Boolean | If it's wishlist page | true |
vendorName | String | Vendor name | Vendor |
showVendorName | Boolean | If show vendor name | false |