I am currently working on adding multiple hotkeys to an application. My goal is to have key combinations ranging from alt+1 to alt+9.
Interestingly, the alt+1 combination is functioning perfectly (breakpoint reached), but I am encountering issues with alt+2 (breakpoint not reached).
Could someone provide insight into this matter?
@HostListener('document:keydown.alt.1', ['$event'])
doThis(e: KeyboardEvent) {
// action();
e.preventDefault();
}
@HostListener('document:keydown.alt.2', ['$event'])
doThat(e: KeyboardEvent) {
// action();
e.preventDefault();
}