Documentation
Feedback
Guides
VTEX IO Apps

VTEX IO Apps
Product Recommendation
Official extension
Version: 2.7.0
Latest version: 2.7.0

Warning

Hello! Thanks for checking out this app. It's currently under development and research by the VTEX Search and Personalization team. During this phase, the app should only be installed on selected accounts. If you're not in contact with the VTEX Search and Personalization team, installing this app on your workspace will not have any effect. If you have any questions, please contact our Support.

Description

The VTEX Recommendation Shelf app is a store component that displays a collection of products using recommendation strategies.

An error occurred while loading the image ./shelf.png

Table of Contents

Prerequisites

Most recommendation strategies rely on user navigation data as input. Therefore, your store must be configured with our pixel for the recommendation-shelf to work properly. This configuration is managed by the VTEX team, so please wait for our confirmation before proceeding with the integration.

Usage

This app uses our store builder with the blocks architecture. To learn more about Store Builder, click here.

To use this app, you need to import it in your store-theme dependencies in the manifest.json file.


_10
"dependencies": {
_10
"vtex.recommendation-shelf": "2.x"
_10
}

Then, add the recommendation-shelf block into your app theme.

Now, you can change the behavior of the shelf block. See an example of how to configure it:


_25
"recommendation-shelf#visual-similarity": {
_25
"blocks": ["list-context.product-list-static"],
_25
"props": {
_25
"recommendationType": "VISUAL_SIMILARITY",
_25
"title": "Similar items"
_25
}
_25
},
_25
"list-context.product-list-static": {
_25
"blocks": [
_25
"product-summary.shelf"
_25
],
_25
"children": [
_25
"slider-layout#recommendation-slider"
_25
]
_25
},
_25
"slider-layout#recommendation-slider": {
_25
"props": {
_25
"itemsPerPage": {
_25
"desktop": 5,
_25
"tablet": 3,
_25
"phone": 2
_25
},
_25
"infinite": true
_25
}
_25
}

Our component relies on two other VTEX components: slider-layout and product-summary.shelf. You can customize the shelf by creating a custom product summary, for example:


_10
"product-summary.shelf#custom": {
_10
"children": [
_10
"product-summary-name",
_10
"product-summary-description",
_10
"product-summary-image",
_10
"product-summary-price",
_10
"product-summary-sku-selector",
_10
"product-summary-buy-button"
_10
]
_10
}

For more information, see the Product Summary API configuration.

Configuration

You can configure the recommendation-shelf block in your theme app using the following props:

Prop nameTypeDescriptionDefault value
recommendationTypeEnumRecommendation strategy used to fetch product suggestions for a user. See Recommendation StrategiesTOP_ITEMS
titlestringTitle to be displayed with the shelf.-
campaignVrnstringVRN identifier for an existing campaign. Takes precedence over recommendationType.-

Recommendation Strategies

Below are the available recommendation strategies that can be used to fetch product suggestions:

strategyDescriptionPages
TOP_ITEMSReturns the most bought products in the storeAny

Some strategies are based on user interest and navigation:

strategyDescriptionPages
PERSONALIZEDReturns products recommended based on the last products clicked by the user in the store.Any
LAST_SEENReturns products recommended based on the last products viewed by the user in the store.Any

Others are based on the current product (recommended for use on store.product pages):

strategyDescriptionPages
CROSS_SELLReturns complementary products related to the current product.store.product
VISUAL_SIMILARITYReturns products considered visually similar to the current product.store.product
SIMILAR_ITEMSReturns products considered most similar to the current product.store.product

Troubleshooting

Check if others have encountered similar issues here. Feel free to open issues or contribute with pull requests.

{"base64":"  ","img":{"width":110,"height":20,"type":"svg","mime":"image/svg+xml","wUnits":"px","hUnits":"px","url":"https://img.shields.io/badge/all_contributors-0-orange.svg?style=flat-square"}}

See also
VTEX App Store
VTEX IO Apps