I am working on a Magento 2.1.7 shop.
On my category pages, I need to have the grid view only, without giving the customer the possibility of switching to the list view.
What is the easiest and/or the most appropriate way to do this?
Magento Stack Exchange is a question and answer site for users of the Magento e-Commerce platform. It only takes a minute to sign up.Sign up to join this community
If needed can be also applied from layout xml
<?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"> <body> <referenceBlock name="product_list_toolbar"> <action method="disableExpanded"/> </referenceBlock> </body> </page>