We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3f0e411 commit 6cfdabfCopy full SHA for 6cfdabf
api/navigation.js
@@ -12,4 +12,15 @@ export const NavigationHistoryEntry = currentEntry
12
? Object.getPrototypeOf(currentEntry).constructor
13
: class NavigationHistoryEntry extends EventTarget {}
14
15
-export default globalThis.navigation ? globalThis.navigation : new Navigation()
+export const navigation = globalThis.navigation ? globalThis.navigation : new Navigation()
16
+export default navigation
17
+
18
+if (!('activation' in navigation) && globalThis.window) {
19
+ globalThis.addEventListener('pageswap', (e) => {
20
+ if (e.activation) {
21
+ try {
22
+ navigation.activation = e.activation
23
+ } catch {}
24
+ }
25
+ })
26
+}
0 commit comments