Magento – Magento2: How to remove ‘My Orders’ in Luma sidebar

blocksmagento2orderssidebar

This just suddenly showed up in my left sidebar. It says "My Orders" with a list of past purchases and an "Add to Cart" button. What is this? The block hint is "Magento\Sales\Block\Reorder\Sidebar".

I've tried "referenceBlock name="sidebar.Reorder" remove="true" in my default.xml but that doesn't work.

Any help is appreciated. Thanks.

V 2.0.13 Luma child theme

Best Answer

You have to keep below code in your default.xml file to remove unnecessary block from sidebar.

 <?xml version="1.0"?>
    <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd" layout="3columns">
        <body>    
            <!-- Compare and wishlist sidebar -->
            <referenceBlock name="catalog.compare.sidebar" remove="true"/>
            <referenceBlock name="wishlist_sidebar" remove="true" />
            <!-- Recently order -->
            <referenceBlock name="sale.reorder.sidebar" remove="true" />
            <!-- additional sidebar block -->
            <referenceContainer name="sidebar.additional" remove="true" />
        </body>
    </page>