Integrate a search-as-you-type experience into your Vue app.
npm create
tool to install base dependencies and create your app folder structure.
vue-instantsearch
, @meilisearch/instant-meilisearch
, and instantsearch.css
.
main.js
to include the Vue InstantSearch library.
App.vue
file.
ais-instant-search
widget is the mandatory wrapper that allows you to configure your search. It takes two props: the search-client
and the index-name
.
ais-search-box
and ais-hits
widgets inside the ais-instant-search
wrapper widget.
Import the CSS library to style the search components.
.ais-InstantSearch
, .ais-SearchBox
, .ais-InfiniteHits-list
, .ais-InfiniteHits-item
localhost:5173
), and start searching.