Log in
Model

Item

Magento\Catalog\Model\Layer\Filter\Item

What it does

This class represents an individual filter option in Magento 2's layered navigation (e.g., a specific color, price range, or category).

Developers use it to display filter options on catalog pages and generate URLs for applying, removing, or clearing filters.

Each Item object contains the filter value, label, and methods to create the necessary navigation links.

Public Methods

  • getFilter()
  • getUrl()
  • getRemoveUrl()
  • getClearLinkUrl()
  • getName()
  • getValueString()