bs-typeahead Bootstrap Autocomplete Library Demos

Download This Plugin Back To jQueryScript

A JavaScript autocomplete/typeahead library for Bootstrap forms with local arrays, async sources, ARIA support, and custom results.

Local Objects

Search city objects by name and return their numeric IDs.

displayField + valueField
Selection appears here.

Custom Fields

Use non-standard object keys for matching and selected values.

Name / ID
Selection appears here.

String Source

Plain string arrays work without field configuration.

source: string[]
Selection appears here.

Async Fetcher

Simulates a network request with debounce, loading state, and cancellation.

debounceMs + AbortSignal
Waiting for input.

Scrollable Menu

Large result sets stay contained with maxItems and maxHeight.

maxHeight
Selection appears here.

Manual Highlight

Enter selects only after you move onto an option with the arrow keys.

autoSelect: false
Selection appears here.

Custom Renderer

Render each option with extra metadata while keeping keyboard behavior.

renderItem
Selection appears here.

Custom Matcher and Empty State

Match by code, city, or country and show a menu message when nothing matches.

matcher + renderEmpty
Selection appears here.

ARIA and Events

Watch combobox attributes and emitted events change as you type and select.

open / load / select
Selection appears here.