@exapps/vue-finder-live
v1.1.6
Published
Easy to use component for live-search, supports multi results with titles and footer elements
Downloads
4
Readme
VueFinderLive
VueFinderLive is a versatile and dynamic live search component for vue applications. It enables users to perform real-time searches, displaying multiple results instantly as the user types. This component is designed to enhance user experience by providing quick, responsive search capabilities that can be easily integrated into any vue project.
Features
- Real-time search functionality
- Supports multiple search results
- Easy integration with vue applications
- Customizable appearance and behavior
- Debounce to limit search rate for performance optimization
Installation
npm install @exapps/vue-finder-live --save
Usage
import { VueFinderLive } from '@exapps/vue-finder-live';
<VueFinderLive
v-model="value"
:inputTextName="['name']"
:resultsTextName="['nr', 'name']"
@selected="selected"
@search="search"/>
function search(event) {
event.addResult(async () => {
return (await axios.get(route('some-search-route'))).data
}, 'Title 1')
event.addResult(async () => {
return (await axios.get(route('some-search-route-2'))).data
}, 'Title 2')
}
function selected(item) {
console.log(item)
}