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
important point for me is, events can be delegated, that is, they can be assigned to elements that are added dynamically to the page later. it doesnt specifically say so in the docs, had to test it .. but it seems to work just fine
$(document).on('tap','.photo',function() {
alert('you tapped on a photo that wasnt here when i bound this event');
});
The text was updated successfully, but these errors were encountered:
benmajor
added
the
invalid
The issue is invalid, the problem is outside the scope of developer support, or another invalidity.
label
Oct 30, 2014
Thanks for your comments. The documentation does state:
All of the events outlined above have been written using jQuery's event.special object, and so can be used in conjunction with jQuery's event handling functions, as well as shortcut wrappers.
I think that covers event delegation, so I'll mark this as an invalid.
Hi
great lib.
important point for me is, events can be delegated, that is, they can be assigned to elements that are added dynamically to the page later. it doesnt specifically say so in the docs, had to test it .. but it seems to work just fine
$(document).on('tap','.photo',function() { alert('you tapped on a photo that wasnt here when i bound this event'); });
The text was updated successfully, but these errors were encountered: