useSearchSuggest
This hook provides access to search suggestion terms from the block data, typically used to render search suggestion chips or tags.
Import
import { useSearchSuggest } from '@appmaker-xyz/shopify';
Basic Usage
const { data, terms } = useSearchSuggest({ blockData });
Parameters
| Parameter | Type | Description |
|---|---|---|
blockData | Object | Block data containing search suggestion terms. |
Return Value
| Property | Type | Description |
|---|---|---|
data | Object | The raw block data passed to the hook. |
terms | Array | Array of search suggestion term objects. Empty array if no terms available. |