JSFiddle - React, Tailwind, and code Playground
by doug65536
JavaScript
$(function() {
var real_on = $.fn.on;
(function() {
$.fn.on = function() {
var elements = [];
this.each(function() {
elements.push(this);
});
console.log("on called-------------");
console.log(elements);
console.log(arguments);
// Call real on handler
return real_on.apply(this, arguments);
};
}());
});
$(window).on('resize', function() {
$('body').append($('<p>').text('got resize'));
});