@algolia/client-search 5.12.0 → 5.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -41,11 +41,11 @@ All of our clients comes with type definition, and are available for both browse
41
41
  ### With a package manager
42
42
 
43
43
  ```bash
44
- yarn add @algolia/client-search@5.12.0
44
+ yarn add @algolia/client-search@5.14.0
45
45
  # or
46
- npm install @algolia/client-search@5.12.0
46
+ npm install @algolia/client-search@5.14.0
47
47
  # or
48
- pnpm add @algolia/client-search@5.12.0
48
+ pnpm add @algolia/client-search@5.14.0
49
49
  ```
50
50
 
51
51
  ### Without a package manager
@@ -53,7 +53,7 @@ pnpm add @algolia/client-search@5.12.0
53
53
  Add the following JavaScript snippet to the <head> of your website:
54
54
 
55
55
  ```html
56
- <script src="https://cdn.jsdelivr.net/npm/@algolia/client-search@5.12.0/dist/builds/browser.umd.js"></script>
56
+ <script src="https://cdn.jsdelivr.net/npm/@algolia/client-search@5.14.0/dist/builds/browser.umd.js"></script>
57
57
  ```
58
58
 
59
59
  ### Usage
package/dist/browser.d.ts CHANGED
@@ -3041,7 +3041,7 @@ type ReplaceAllObjectsOptions = {
3041
3041
  batchSize?: number;
3042
3042
  };
3043
3043
 
3044
- declare const apiClientVersion = "5.12.0";
3044
+ declare const apiClientVersion = "5.14.0";
3045
3045
  declare function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }: CreateClientOptions): {
3046
3046
  transporter: _algolia_client_common.Transporter;
3047
3047
  /**
@@ -19,7 +19,7 @@ import {
19
19
  getAlgoliaAgent,
20
20
  shuffle
21
21
  } from "@algolia/client-common";
22
- var apiClientVersion = "5.12.0";
22
+ var apiClientVersion = "5.14.0";
23
23
  function getDefaultHosts(appId) {
24
24
  return [
25
25
  {
@@ -255,6 +255,7 @@ function createSearchClient({
255
255
  indexName,
256
256
  browseParams: {
257
257
  cursor: previousResponse ? previousResponse.cursor : void 0,
258
+ hitsPerPage: 1e3,
258
259
  ...browseParams
259
260
  }
260
261
  },
@@ -294,7 +295,7 @@ function createSearchClient({
294
295
  requestOptions
295
296
  );
296
297
  },
297
- validate: (response) => response.nbHits < params.hitsPerPage,
298
+ validate: (response) => response.hits.length < params.hitsPerPage,
298
299
  ...browseRulesOptions
299
300
  });
300
301
  },
@@ -334,7 +335,7 @@ function createSearchClient({
334
335
  params.page += 1;
335
336
  return resp;
336
337
  },
337
- validate: (response) => response.nbHits < params.hitsPerPage,
338
+ validate: (response) => response.hits.length < params.hitsPerPage,
338
339
  ...browseSynonymsOptions
339
340
  });
340
341
  },