instantsearch.js 4.75.6 → 4.75.7
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/cjs/lib/utils/getAppIdAndApiKey.js +4 -1
- package/cjs/lib/version.js +1 -1
- package/dist/instantsearch.development.js +6 -3
- package/dist/instantsearch.development.js.map +1 -1
- package/dist/instantsearch.production.min.js +2 -2
- package/dist/instantsearch.production.min.js.map +1 -1
- package/es/lib/utils/getAppIdAndApiKey.d.ts +1 -1
- package/es/lib/utils/getAppIdAndApiKey.js +4 -1
- package/es/lib/version.d.ts +1 -1
- package/es/lib/version.js +1 -1
- package/package.json +5 -5
|
@@ -6,7 +6,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.getAppIdAndApiKey = getAppIdAndApiKey;
|
|
7
7
|
// typed as any, since it accepts the _real_ js clients, not the interface we otherwise expect
|
|
8
8
|
function getAppIdAndApiKey(searchClient) {
|
|
9
|
-
if (searchClient.
|
|
9
|
+
if (searchClient.appId && searchClient.apiKey) {
|
|
10
|
+
// searchClient v5
|
|
11
|
+
return [searchClient.appId, searchClient.apiKey];
|
|
12
|
+
} else if (searchClient.transporter) {
|
|
10
13
|
// searchClient v4 or v5
|
|
11
14
|
var transporter = searchClient.transporter;
|
|
12
15
|
var headers = transporter.headers || transporter.baseHeaders;
|
package/cjs/lib/version.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! InstantSearch.js 4.75.
|
|
1
|
+
/*! InstantSearch.js 4.75.7 | © Algolia, Inc. and contributors; MIT License | https://github.com/algolia/instantsearch */
|
|
2
2
|
(function (global, factory) {
|
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
4
4
|
typeof define === 'function' && define.amd ? define(factory) :
|
|
@@ -1172,7 +1172,10 @@
|
|
|
1172
1172
|
|
|
1173
1173
|
// typed as any, since it accepts the _real_ js clients, not the interface we otherwise expect
|
|
1174
1174
|
function getAppIdAndApiKey(searchClient) {
|
|
1175
|
-
if (searchClient.
|
|
1175
|
+
if (searchClient.appId && searchClient.apiKey) {
|
|
1176
|
+
// searchClient v5
|
|
1177
|
+
return [searchClient.appId, searchClient.apiKey];
|
|
1178
|
+
} else if (searchClient.transporter) {
|
|
1176
1179
|
// searchClient v4 or v5
|
|
1177
1180
|
var transporter = searchClient.transporter;
|
|
1178
1181
|
var headers = transporter.headers || transporter.baseHeaders;
|
|
@@ -16098,7 +16101,7 @@
|
|
|
16098
16101
|
};
|
|
16099
16102
|
}
|
|
16100
16103
|
|
|
16101
|
-
var version$1 = '4.75.
|
|
16104
|
+
var version$1 = '4.75.7';
|
|
16102
16105
|
|
|
16103
16106
|
var withUsage$v = createDocumentationMessageGenerator({
|
|
16104
16107
|
name: 'instantsearch'
|