react-instantsearch-nextjs 0.3.13 → 0.3.15
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.
|
@@ -18,7 +18,6 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
18
18
|
function useInstantSearchRouting(passedRouting, isMounting) {
|
|
19
19
|
var pathname = (0, _navigation.usePathname)();
|
|
20
20
|
var searchParams = (0, _navigation.useSearchParams)();
|
|
21
|
-
var router = (0, _navigation.useRouter)();
|
|
22
21
|
var routingRef = (0, _react.useRef)();
|
|
23
22
|
var onUpdateRef = (0, _react.useRef)();
|
|
24
23
|
(0, _react.useEffect)(function () {
|
|
@@ -43,9 +42,7 @@ function useInstantSearchRouting(passedRouting, isMounting) {
|
|
|
43
42
|
if (this.isDisposed) {
|
|
44
43
|
return;
|
|
45
44
|
}
|
|
46
|
-
|
|
47
|
-
scroll: false
|
|
48
|
-
});
|
|
45
|
+
history.pushState({}, '', url);
|
|
49
46
|
};
|
|
50
47
|
browserHistoryOptions.start = function start(onUpdate) {
|
|
51
48
|
onUpdateRef.current = onUpdate;
|
|
@@ -6,12 +6,11 @@ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input ==
|
|
|
6
6
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
7
7
|
import historyRouter from "instantsearch.js/es/lib/routers/history.js";
|
|
8
8
|
import { headers } from "next/headers.js";
|
|
9
|
-
import { usePathname, useSearchParams
|
|
9
|
+
import { usePathname, useSearchParams } from "next/navigation.js";
|
|
10
10
|
import { useRef, useEffect } from 'react';
|
|
11
11
|
export function useInstantSearchRouting(passedRouting, isMounting) {
|
|
12
12
|
var pathname = usePathname();
|
|
13
13
|
var searchParams = useSearchParams();
|
|
14
|
-
var router = useRouter();
|
|
15
14
|
var routingRef = useRef();
|
|
16
15
|
var onUpdateRef = useRef();
|
|
17
16
|
useEffect(function () {
|
|
@@ -36,9 +35,7 @@ export function useInstantSearchRouting(passedRouting, isMounting) {
|
|
|
36
35
|
if (this.isDisposed) {
|
|
37
36
|
return;
|
|
38
37
|
}
|
|
39
|
-
|
|
40
|
-
scroll: false
|
|
41
|
-
});
|
|
38
|
+
history.pushState({}, '', url);
|
|
42
39
|
};
|
|
43
40
|
browserHistoryOptions.start = function start(onUpdate) {
|
|
44
41
|
onUpdateRef.current = onUpdate;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-instantsearch-nextjs",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.15",
|
|
4
4
|
"description": "React InstantSearch SSR utilities for Next.js",
|
|
5
5
|
"types": "dist/es/index.d.ts",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -49,13 +49,13 @@
|
|
|
49
49
|
"watch:es": "yarn --silent build:es:base --watch"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
|
-
"instantsearch.js": "4.75.
|
|
52
|
+
"instantsearch.js": "4.75.2",
|
|
53
53
|
"next": "13.5.1",
|
|
54
|
-
"react-instantsearch-core": "7.13.
|
|
54
|
+
"react-instantsearch-core": "7.13.5"
|
|
55
55
|
},
|
|
56
56
|
"peerDependencies": {
|
|
57
|
-
"next": ">= 13.4
|
|
58
|
-
"react-instantsearch": ">= 7.1.0
|
|
57
|
+
"next": ">= 13.4 < 15",
|
|
58
|
+
"react-instantsearch": ">= 7.1.0 < 8"
|
|
59
59
|
},
|
|
60
|
-
"gitHead": "
|
|
60
|
+
"gitHead": "c5f9a44d3f97363b1a0486a18696edbeafc193d5"
|
|
61
61
|
}
|