JSFiddle - React, Tailwind, and code Playground

HTML

<img src="http://i.imgur.com/o46X87d.png" id="1" class="btnClick" />


<a href="google.com" id="checkLink"></a>

JavaScript

$('.btnClick').on('click',function(){   $(this).attr('src','https://placekitten.com/g/200/300')
 $(this).attr('href','google.com')

});