There was a report somewhere (can't find it anymore) about bad performance on Android, and the suggestion to avoid using live event handlers. I had some rather bad performance on Android, but haven't yet been able to verify that the live event stuff is responsible for that.
So in case someone can test this, these are the current usages of live() in jQuery Mobile:
- jquery.mobile.buttonMarkup.js, line 85: mouse event for buttons
- jquery.mobile.fixHeaderFooter.js, line 73 and 87: custom events for pagebeforeshow and pageshow
- jquery.mobile.listview.filter.js, line 11: custom event for listviewcreate
- jquery.mobile.navigation.js, line 374 and 404: binding submit event for forms and click events for anchors
The first step would be replacing live with delegate, so instead of
- $( "a" ).live( "click", function(event) {
Use
- $( document ).delegate( "a", "click", function(event) {
So independent of the result, is there any reason to use live instead of delegate? With delegate we avoid the initial selection overhead.