JSFiddle - React, Tailwind, and code Playground
HTML
<h2>Click the red box</h2>
<div class="canvas"></div>
<div id="event"></div>
CSS
.canvas {
height: 50px;
width: 50px;
background: red;
}
#event {margin-top: 10px;}
strong {color: red;}
JavaScript
$('.canvas').mousedown(function(argument){
lasEvent = argument;
console.log(lasEvent);
$("#event").html("The event type is <strong>" + lasEvent.type + "</strong>");
})