Skip to main content
Since May 1st, 2024, Apple requires all iOS apps to include a privacy manifest. For more details, see Privacy Manifest.

Instant results

When using the instant results pattern, you retrieve results with each keystroke and display them on the results page. This approach is most effective either when the dataset is limited or when users have a well-defined idea of what they’re looking for. For this instant results strategy to provide a good user experience, very fast response time is required to allow the results to be refreshed β€œinstantly” on each keystroke. For more information, see the blog post about instant results.

Usage

With InstantSearch iOS, you get instant results by default: you can specify searchTriggeringMode = .searchOnSubmit on the SearchBox to turn it off.
Swift
// For an Instant Results experience:
searchBoxInteractor.connectSearcher(searcher) // default value of searchTriggeringMode parameter is .searchAsYouType

// Alternatively, for a Search on Submit experience:
searchBoxInteractor.connectSearcher(searcher, searchTriggeringMode: searchOnSubmi)
⌘I