You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
hey @d4rkr00t I'm working on an official repo with tests and improvements, where possible.
I wonder what do you think about this possibility, which is already actually implemented in 0.1.1
Handler.add(document.documentElement,{clickTarget: '.our-selector-for-check',click: function(e){// do what's needed to be done with // e.target, the node with class .our-selector-for-check// or e.currentTarget, which is the initial node}});
I've actually made this feature smart enough to recognize one or more handlers, like:
Handler.add($('.list'),{clickTarget: ['ul.main','ul.main > li'],click: function(e){// do what's needed to be done with // outer UL or its nested LI}});
Long story short, the explicit intent is to use a different event target so I found the name more appropriate, and the ability to set more than one target a good idea too.
The default handleEvent in this case is not the basic one, but one that requires more checks at runtime … still fast enough, and I think a good compromise anyway.
hey @d4rkr00t I'm working on an official repo with tests and improvements, where possible.
I wonder what do you think about this possibility, which is already actually implemented in
0.1.1
I've actually made this feature smart enough to recognize one or more handlers, like:
Long story short, the explicit intent is to use a different event
target
so I found the name more appropriate, and the ability to set more than one target a good idea too.The default
handleEvent
in this case is not the basic one, but one that requires more checks at runtime … still fast enough, and I think a good compromise anyway.Thoughts ?