-
Notifications
You must be signed in to change notification settings - Fork 66
Closed
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomers
Description
Description
see #48
Thanks a lot to @haoyun for raising this
When using typescript a searchClient has to response to the search client interface
export type SearchClient = {
search: DefaultSearchClient['search'];
searchForFacetValues: DefaultSearchClient['searchForFacetValues'];
addAlgoliaAgent?: DefaultSearchClient['addAlgoliaAgent'];
initIndex?: (
indexName: string
) => SearchIndex extends { findAnswers: any }
? Partial<Pick<SearchIndex, 'findAnswers'>>
: SearchIndex;
};Accessible here: https://github.com/algolia/instantsearch.js/blob/16cc34155d8af25893db3e521b4a1da26ce591e4/src/types/algoliasearch.ts#L33-L42
Until recently it was an optional method.
Expected behavior
The method should be present to make instantMeiliSearch usable with typescript
Current behavior
As the method is missing it does not work on typescript projects
Environment (please complete the following information):
- instantsearch.js version: [e.g. v4.23.0]
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomers