Documentation
Feedback
Guides
VTEX IO Apps

VTEX IO Apps
Product Summary List
vtex.product-summary
Version: 2.92.2
Latest version: 2.92.2

Source code

The Product Summary List app (list-context.product-list) creates product lists in VTEX stores. It fetches product data and passes it to the product-summary.shelf block, which renders each product summary.

Use this app to build shelves, product carousels, and other storefront sections that display products.

{"base64":"  ","img":{"width":1919,"height":951,"type":"png","mime":"image/png","wUnits":"px","hUnits":"px","length":437866,"url":"https://cdn.jsdelivr.net/gh/vtexdocs/dev-portal-content@main/images/vtex-product-summary-productsummarylist-0.png"}}

Installation

  1. Install the product-summary app in your account by running the following command in your terminal:

_10
vtex install vtex.product-summary

Configuration

  1. Open you Store Theme app in a code editor.
  2. Open the manifest.json file and add the Product Summary List app (vtex.product-summary) under dependencies.

_10
"dependencies": {
_10
"vtex.product-summary": "2.x"
_10
}

You can now use the list-context.product-list block, which is exported by the product-summary app.

product-list block

Use this block to define the product-summary variation for creating the product list and the desired list-context.product-list, as shown below:


_14
"product-summary.shelf#demo1": {
_14
"children": [
_14
"stack-layout#prodsum",
_14
"product-summary-name",
_14
"product-rating-inline",
_14
"product-summary-space",
_14
"product-summary-price",
_14
"product-summary-buy-button"
_14
]
_14
},
_14
"list-context.product-list#demo1": {
_14
"blocks": ["product-summary.shelf#demo1"],
_14
"children": ["slider-layout#demo-products"]
_14
},

Props

list-context.product-list also runs the GraphQL query that fetches the product list, allowing it to receive the following props:

Prop nameTypeDescriptionDefault value
categorystringCategory ID of the listed items. For subcategories, use "/" (example: "1/2/3").-
specificationFiltersArray({ id: String, value: String })Specification filters of the listed items.[]
collectionstringID of the product collection to display.-
orderByenumSort order for the items. Possible values are: '', OrderByTopSaleDESC, OrderByReleaseDateDESC, OrderByBestDiscountDESC, OrderByPriceDESC, OrderByPriceASC, OrderByNameASC, OrderByNameDESC.OrderByTopSaleDESC
hideUnavailableItemsbooleanHides unavailable items when set to true.false
maxItemsnumberMaximum number of items to fetch.10
skusFilterSkusFilterEnumControls which SKUs are returned for each product. Returning fewer SKUs improves shelf query performance. Possible values are: FIRST_AVAILABLE, ALL_AVAILABLE, ALL."ALL_AVAILABLE"
installmentCriteriaInstallmentCriteriaEnumControls which price is displayed when a product has multiple installment options. Possible values are: MAX_WITHOUT_INTEREST, MAX_WITH_INTEREST."MAX_WITHOUT_INTEREST"
listNamestringName of the list property for Google Analytics events.-
preferredSKUPreferredSKUEnumDefines which SKU is selected in the summary. Possible values are: FIRST_AVAILABLE, LAST_AVAILABLE, PRICE_ASC, PRICE_DESC."FIRST_AVAILABLE"

SkusFilterEnum

NameValueDescription
First AvailableFIRST_AVAILABLEBest performance, ideal if you don't have a SKU selector on your shelf. Returns only the first available SKU for that product in your query.
All AvailableALL_AVAILABLEIt only returns available SKUs. Ideal if you have a SKU selector and want better performance.
AllALLLowest performance. Returns all SKUs for each product, including unavailable ones.

InstallmentCriteriaEnum

NameValueDescription
Maximum without interestMAX_WITHOUT_INTERESTDisplays the maximum number of interest-free installments.
MaximumMAX_WITH_INTERESTDisplays the maximum number of installments, including those with interest.

PreferredSKUEnum

NameValueDescription
First AvailableFIRST_AVAILABLESelects the first available SKU.
Last AvailableLAST_AVAILABLESelects the last available SKU.
Most ExpensivePRICE_DESCSelects the most expensive available SKU.

To override the preferredSKU prop, create a product specification and assign the SKU value you want selected by default for each product. If the specification doesn't exist or the value is empty, the preferredSKU prop is used as a fallback.

See also
Vtex.product Summary
VTEX IO Apps
VTEX App Store
VTEX IO Apps
Was this helpful?