JSFiddle - React, Tailwind, and code Playground
HTML
<div id='div1'>
Click Me
</div>
<p id="url1"></p>
CSS
#div1{
width:200px;
background-color:#ccc;
}
JavaScript
$(document).ready(function(){
$('#div1').click(function(){
$("#url1").html(location.href);
});
});