How to remove “Add to Compare” links in sidebar and product page in Magento 2 product pages
Magento 2 Community has a default feature of comparison lists for multiple products. Learn how you can disable the “Add to Compare” feature in magento2 community edition.
Add the following lines in default.xml of your theme folder
<referenceBlock name="catalog.compare.sidebar" remove="true"/> <referenceBlock name="catalog.compare.link" remove="true"/> <referenceBlock name="related.product.addto.compare" remove="true"/> <referenceBlock name="view.addto.compare" remove="true"/> <referenceBlock name="upsell.product.addto.compare" remove="true"/>
Leave a Reply