Skip to content
This repository has been archived by the owner on Jan 21, 2024. It is now read-only.

Commit

Permalink
[release-2.0] fix: the global search keyboard event is not removed wh…
Browse files Browse the repository at this point in the history
…en the component is unmounted (#772)

This is an automated cherry-pick of #767

/assign JohnNiang

```release-note
None
```
  • Loading branch information
halo-dev-bot authored Dec 14, 2022
1 parent a3caa29 commit ec6f39d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/layouts/BasicLayout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ onMounted(() => {
});
onUnmounted(() => {
document.addEventListener("keydown", handleGlobalSearchKeybinding);
document.removeEventListener("keydown", handleGlobalSearchKeybinding);
});
// Generate menus by routes
Expand Down

0 comments on commit ec6f39d

Please sign in to comment.