-
Notifications
You must be signed in to change notification settings - Fork 530
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(index): replicate searchFunction hack (#4078)
This PR replicates [the hack](https://github.com/algolia/instantsearch.js/blob/509513c0feafaad522f6f18d87a441559f4aa050/src/lib/RoutingManager.ts#L113-L130) implemented inside `RoutingManager` for the `searchFunction`. The `uiState` is now a first-class citizen so we have to apply this logic to the index. I've tried to keep the same process: the update is triggered once all the widgets of the index are rendered like it was the case inside the manager (since it was always the last widget). At the moment the call to notify the instance that a change occurs isn't implemented because we don't expose the function (yet). Once the API is available I'll update the PR. The pieces that need to be updated are commented.
- Loading branch information
Showing
2 changed files
with
201 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters