Javascript .on(‘click’ is not working on span

So I’ve spend already 2 days trying to solve this. I have a <span class=”faicon-add” data-id=”id_object_places_proximity_keys-0-place_icon” rel=”faicon-add”> and a jquery script loaded The problem is that $(‘.faicon-add’).on(‘click’, function(){ won’t trigger… I’ve tried to add onclick=”open_modal();” and directly placing this function under that span And it worked, but that is not a solution for me, because I need to give a modal that icon_field variable… Also I tried to add only $(‘.faicon-add’).on(‘click’, function(){ function in the Google DevTools console. Then when I click on span, modal is showing up… That’s weird… I’ve also tried to load script containing also only $(‘.faicon-add’).on(‘click’,