JSFiddle - React, Tailwind, and code Playground
HTML
<html>
<body>
<a id="preventlink" href="http://youtube.com"> click here </a>
<script src="js/jquery-1.11.3.min.js"> </script>
</body>
</html>
JavaScript
var link=document.getElementById("preventlink")
link.addEventListener("click", function(e) {
e.preventDefault()}, false)