Let's say we have this event:
$('form.ajax-form').on('submit', (e) => {
e.preventDefault();
console.log($(this));
});
This event is dispatching only when I submit the form, right? so it doesn't have to be nested in document ready event. When I submit my form, I get this output:
r.fn.init {}
I'm assuming it has to do something with jQuery initiating, but who is it related to my code? what am I missing here? It didn't happen to me in previous versions..
Edit 1 - I'm expecting to see the HTML of the element.