needs improvement - JS. Proper Event Binding



Our HTML template has been soft rejected for the following reason:

PROPER EVENT BINDING: Consider using the preferred .on() method
rather than .click(), .bind(), .hover(), etc. For best performance and
concise code use event delegation whenever possible:

please can you help me , how can solve the problem


Where you have in custom JS code, for example:


replace with:

jQuery(’#selector’).on(‘click’, …

Ans so on for click, bind, hover, ready, load, resize…


thks a lot