Skip to content

Commit

Permalink
fix(MainLayout): remove event listeners on navigate
Browse files Browse the repository at this point in the history
  • Loading branch information
Jabster28 committed Aug 17, 2020
1 parent e7ca803 commit b1bb61e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/layouts/MainLayout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,11 @@ export default {
};
this.checkFs();
},
beforeDestroy() {
window.removeEventListener('online', this.checkConn);
window.removeEventListener('offline', this.checkConn);
window.removeEventListener('resize', this.checkFs);
},
watch: {
$route() {
this.$q.loading.setDefaults({
Expand Down

1 comment on commit b1bb61e

@vercel
Copy link

@vercel vercel bot commented on b1bb61e Aug 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.