@tinkoff/router 0.6.274 → 0.6.280
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.
|
@@ -130,6 +130,9 @@ class ClientRouter extends AbstractRouter {
|
|
|
130
130
|
await this.blockHook.callPromise({ navigation });
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
133
|
+
// Reset the current navigation to prevent reusing a stale navigation state
|
|
134
|
+
// if the user returns to the page in the same state (e.g. via bfcache restoration).
|
|
135
|
+
this.currentNavigation = null;
|
|
133
136
|
// prevent routing from any continues navigation returning promise which will be not resolved
|
|
134
137
|
return new Promise(() => { });
|
|
135
138
|
}
|
package/lib/router/client.es.js
CHANGED
|
@@ -130,6 +130,9 @@ class ClientRouter extends AbstractRouter {
|
|
|
130
130
|
await this.blockHook.callPromise({ navigation });
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
133
|
+
// Reset the current navigation to prevent reusing a stale navigation state
|
|
134
|
+
// if the user returns to the page in the same state (e.g. via bfcache restoration).
|
|
135
|
+
this.currentNavigation = null;
|
|
133
136
|
// prevent routing from any continues navigation returning promise which will be not resolved
|
|
134
137
|
return new Promise(() => { });
|
|
135
138
|
}
|
package/lib/router/client.js
CHANGED
|
@@ -134,6 +134,9 @@ class ClientRouter extends abstract.AbstractRouter {
|
|
|
134
134
|
await this.blockHook.callPromise({ navigation });
|
|
135
135
|
return;
|
|
136
136
|
}
|
|
137
|
+
// Reset the current navigation to prevent reusing a stale navigation state
|
|
138
|
+
// if the user returns to the page in the same state (e.g. via bfcache restoration).
|
|
139
|
+
this.currentNavigation = null;
|
|
137
140
|
// prevent routing from any continues navigation returning promise which will be not resolved
|
|
138
141
|
return new Promise(() => { });
|
|
139
142
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tinkoff/router",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.280",
|
|
4
4
|
"description": "router",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"typings": "lib/index.d.ts",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"use-sync-external-store": "^1.4.0"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {
|
|
31
|
-
"@tramvai/core": "6.82.
|
|
31
|
+
"@tramvai/core": "6.82.19",
|
|
32
32
|
"react": ">=16.14.0",
|
|
33
33
|
"tslib": "^2.4.0"
|
|
34
34
|
},
|