We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 953235a commit a8aa40aCopy full SHA for a8aa40a
src/stateDirectives.js
@@ -145,9 +145,9 @@ function $StateRefDirective($state, $timeout) {
145
146
if (!type.clickable) return;
147
hookFn = clickHook(element, $state, $timeout, type, function() { return def; });
148
- element.bind("click", hookFn);
+ element[element.on ? 'on' : 'bind']("click", hookFn);
149
scope.$on('$destroy', function() {
150
- element.unbind("click", hookFn);
+ element[element.off ? 'off' : 'unbind']("click", hookFn);
151
});
152
}
153
};
@@ -197,9 +197,9 @@ function $StateRefDynamicDirective($state, $timeout) {
197
198
199
200
201
202
203
204
205
0 commit comments