JSFiddle - React, Tailwind, and code Playground
by invincible
HTML
<a href="#1">ссылка</a>
<div id="console"></div>
JavaScript
$("a").click(function(){
$('#console').append($(this).attr("href")+'<br />');
$('#console').append($(this).attr("href").toString().split("#")[1]+'<br />');
$('#console').append(this.getAttribute( name, 2 )+'<br />');
var attr = !jQuery.support.hrefNormalized && notxml && special?this.getAttribute( name, 2 ): this.getAttribute( name );
$('#console').append(attr+'<br />');
return false;
});