This is a building block for other Infrangible modules. It allows a module to change properties of page layout elements, for example to add or remove a CSS class on a page section, depending on a setting in the store configuration. This way a frontend module can switch its look and placement through admin settings without each module having to bring its own mechanism.
Merchants normally do not install this module directly. It is pulled in automatically by the modules that need it, for example “Catalog Filter Sorter”.
Features
- Lets modules add text to the beginning or end of a layout element property, replace it, or remove parts of it.
- Changes can be applied only when a configuration setting is enabled, disabled or set to a specific value, so admin settings directly control the frontend layout.
- Values can also be taken from the store configuration, so settings per website and store view are respected.
- Several changes to the same element are applied in a defined order.
Configuration
The module has no settings and no visible features of its own. It works right after installation and only becomes active through the modules that use it.
Good to know
Agencies building their own Magento modules or themes can use it as well to make layout adjustments depend on configuration values.
Installation
Install the module with Composer in your Magento root directory:
composer require infrangible/m2-layout-updateThen enable it and update the store as described in the installation guide. Composer installs the required modules listed on this page automatically.