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 0bfe830 commit 9ab262cCopy full SHA for 9ab262c
src/listener.js
@@ -23,7 +23,7 @@ class Listener {
23
f: Function;
24
25
constructor() {
26
- this.index = 0;
+ this.index = 1;
27
this.listeners = {};
28
29
this.f = (e: KeyboardEvent) => {
@@ -62,9 +62,7 @@ class Listener {
62
fn
63
};
64
65
- this.index += 1;
66
-
67
- return this.index;
+ return this.index++;
68
69
70
remove = (id: number) => {
@@ -73,7 +71,7 @@ class Listener {
73
71
74
72
removeAll = () => {
75
76
77
78
}
79
0 commit comments