Components

<AisHierarchicalMenu>

Hierarchical Menu Widget

Usage

MySearchExperience.vue
<template>
  <div>
    <AisInstantSearch :widgets :configuration>
      <AisHierarchicalMenu
        attribute="hierarchicalCategories.lvl0"
      ></AisHierarchicalMenu>
    </AisInstantSearch>
  </div>
</template>

<script setup lang="ts">
const widgets = computed(() => [
  useAisHierarchicalMenu({
    attributes: [
      "hierarchicalCategories.lvl0",
      "hierarchicalCategories.lvl1",
      "hierarchicalCategories.lvl2",
    ],
  }),
]);
</script>
⚠️ Always pass the attribute parameter to the component. It should match the first element in the attributes list.

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


Copyright © 2023