JSFiddle - React, Tailwind, and code Playground
HTML
<div id="content">
<a href="javascript:void(0)" data-uri="https://stackoverflow.com/questions/ask">
<a href="javascript:void(0)" data-uri="https://stackoverflow.com/questions/ask">
<img src="https://www.gravatar.com/avatar/084f45fb1ccb4bd208ad48dbffcd502f?s=48&d=identicon&r=PG">
</a>
</div>
JavaScript
$("#content a").on("click", function() {
href = $(this).data("uri");
console.log(href);
});