Skip to content

SearchOptions and SearchClient doesn't exists #1321

@pierredelobel62

Description

@pierredelobel62

Hi! 👋

Firstly, thanks for your work on this project! 🙂

Today I used patch-package to patch @algolia/[email protected] for the project I'm working on.

I had an import problem since SearchOptions and SearchClient doesn't exists.

Here is the diff that solved my problem:

diff --git a/node_modules/@algolia/autocomplete-plugin-query-suggestions/dist/esm/createQuerySuggestionsPlugin.d.ts b/node_modules/@algolia/autocomplete-plugin-query-suggestions/dist/esm/createQuerySuggestionsPlugin.d.ts
index 6145477..7d5ddfc 100644
--- a/node_modules/@algolia/autocomplete-plugin-query-suggestions/dist/esm/createQuerySuggestionsPlugin.d.ts
+++ b/node_modules/@algolia/autocomplete-plugin-query-suggestions/dist/esm/createQuerySuggestionsPlugin.d.ts
@@ -1,6 +1,6 @@
 import { AutocompleteState, AutocompleteSource, AutocompletePlugin } from '@algolia/autocomplete-js';
-import { SearchOptions } from '@algolia/client-search';
-import { SearchClient } from 'algoliasearch/lite';
+import { SearchParams } from '@algolia/client-search';
+import { LiteClient } from 'algoliasearch/lite';
 import { AutocompleteQuerySuggestionsHit, AutocompleteSuggestionsPluginTranslations, QuerySuggestionsHit } from './types';
 export declare type CreateQuerySuggestionsPluginParams<TItem extends QuerySuggestionsHit> = {
     /**
@@ -8,7 +8,7 @@ export declare type CreateQuerySuggestionsPluginParams<TItem extends QuerySugges
      *
      * @link https://www.algolia.com/doc/ui-libraries/autocomplete/api-reference/autocomplete-plugin-query-suggestions/createQuerySuggestionsPlugin/#param-searchclient
      */
-    searchClient: SearchClient;
+    searchClient: LiteClient;
     /**
      * The index name.
      *
@@ -22,7 +22,7 @@ export declare type CreateQuerySuggestionsPluginParams<TItem extends QuerySugges
      */
     getSearchParams?(params: {
         state: AutocompleteState<TItem>;
-    }): SearchOptions;
+    }): SearchParams;
     /**
      * A function to transform the provided source.
      *

This issue body was partially generated by patch-package.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions