InstantSearch specs

✏️ edit page

HitsPerPage

Widget example

HTML output

<div class="ais-HitsPerPage">
  <select class="ais-HitsPerPage-select">
    <option class="ais-HitsPerPage-option" value="3">3 per page</option>
    <option class="ais-HitsPerPage-option" value="6">6 per page</option>
  </select>
</div>

CSS classes

Hint: hover classes below to see their position.

name description
.ais-HitsPerPage the root div of the widget
.ais-HitsPerPage-select the select
.ais-HitsPerPage-option the select option

Options

Note: this is a guideline for new InstantSearch flavours, not a rule.

name default value description
items Array of objects with the value, the label and a boolean "default" which decides which item to select by default
transformItems Function which receives the items, which will be called before displaying them. Should return a new array with the same shape as the original array. Useful for mapping over the items to transform, remove or reorder them

Translations

Note: there are no translations for this widget