Prevent initial search

Hi!

Using vue-instant-search, I’m trying to prevent the first ever search (at page load)

I followed this recommendation from the doc, but unless I call helper.search() - which is what I’m trying to prevent - none of the widgets will display

My code looks like

<ais-instant-search
    :index-name="indexName"
    :search-client="searchClient"
    :search-function="searchFunction"
>
    <ais-search-box>
        <template #default="{ refine }">
            <custom-search-box ... />
        <template>
    </ais-search-box>

        <ais-hits />
</ais-instant-search>

Is there something I’m missing?

Thanks in advance :pray:

@website2 which widgets are you seeing not appear? If a search has not been executed, it won’t have any facet information for example (as it would have to fetch this information via that initial search).

Or is your search box not appearing as well? Happy to help further, just let us know! Thanks!

Hi Michael,

I understand the <ais-hits /> would be empty, that’s ok. The issue I’m facing is that the search box itself is not appearing!

The only way I found to make it appear is to call helper.search()

Any clue?

Thank you!