Skip to content

Commit 8e1580c

Browse files
committed
fixed popstate listener, as it may be overwritten with former notation
1 parent f70638f commit 8e1580c

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

app/concepts/matestack/ui/core/app/app.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@ const componentDef = {
1616
}),
1717
mounted: function(){
1818
const self = this;
19-
window.onpopstate = (event) => {
19+
window.addEventListener("popstate", (event) => {
2020
if (isNavigatingToAnotherPage({
2121
origin: self.currentOrigin,
2222
pathName: self.currentPathName,
2323
search: self.currentSearch
2424
}, document.location)){
2525
self.$store.dispatch("navigateTo", {url: document.location.pathname, backwards: true} );
2626
}
27-
}
27+
})
2828
},
2929
components: {
3030
VRuntimeTemplate: VRuntimeTemplate

vendor/assets/javascripts/dist/matestack-ui-core.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/assets/javascripts/dist/matestack-ui-core.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)