1

How to add swatches options for product item to a Recently viewed UI component?

I use the following code to show recently viewed block on the page

<block class="Magento\Catalog\Block\Widget\RecentlyViewed" name="recently_viewed" template="Magento_Catalog::product/widget/viewed/grid.phtml" after="-">
   <arguments>
       <argument name="uiComponent" xsi:type="string">widget_recently_viewed</argument>
       <argument name="page_size" xsi:type="number">4</argument>
       <argument name="show_attributes" xsi:type="string">name,image,price</argument>
       <argument name="show_buttons" xsi:type="string">add_to_cart,add_to_compare,add_to_wishlist</argument>
   </arguments>
</block>
  • Hello Anton, Have you got an answer to this? – Deepak Shinde 10 hours ago

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.