JSFiddle - React, Tailwind, and code Playground

by kodisha

HTML

<html>
    <head>
    </head>
<body>
    
    <input id="button" type="button" value="push me" />
</body>
</html>

JavaScript

$('button').click(function(){
    console.log('test');
    $(body).trigger('ping');
});


$(body).bind('ping', function(data){
    console.log(data);
})