Components

<AisSortBy>

Sort by widget

Usage

MySearchExperience.vue
<template>
  <div>
    <AisInstantSearch :widgets :configuration>
      <AisSortBy></AisSortBy>
    </AisInstantSearch>
  </div>
</template>

<script setup lang="ts">
const widgets = computed(() => [
  useAisSortBy({
    items: [
      { value: "instant_search", label: "Default" },
      { value: "instant_search_price_asc", label: "Price asc." },
      { value: "instant_search_price_desc", label: "Price desc." },
    ],
  }),
]);
</script>

Slots, props and widget connector params are all typed! More thorough documentation coming soon :)


Copyright © 2023