javascript - touchend event triggers twice using Meteor -
i have list of items on mobile app (iphone), , have "more" button adds more list items. catch touch event on "more" button, add more items list, , item appears "more" button triggered!
template.more.events({ 'touchend li[name=more]': function (evt, template) { var nperpage = session.get("nperpage"); console.log("more"); session.set("nperpage", nperpage+moreincrement); } })
any ideas? open other solutions -- tried figure out how trigger event when "more" button becomes visible...
on event handler try
e.stoppropagation() e.preventdefault()
return false event handler
Comments
Post a Comment