sortFacetValuesBy property

  1. @RequiredMeiliServerVersion('1.3.0')
Map<String, FacetingSortTypes>? sortFacetValuesBy
final

Defines how facet values are sorted.

By default, all facets (*) are sorted by name, alphanumerically in ascending order (alpha).

count sorts facet values by the number of documents containing a facet value in descending order.

example: "*": 'alpha "genres": count

Implementation

@RequiredMeiliServerVersion('1.3.0')
final Map<String, FacetingSortTypes>? sortFacetValuesBy;