JSFiddle - React, Tailwind, and code Playground
HTML
<a href="javascript:void(0);" onclick="a1();">click</a>
<div id="focusme">
<input type="text"/>
<input type="text"/>
</div>
CSS
#focusme {width:400px; height:100px; overflow-y:scroll; }
JavaScript
function a1()
{
alert("1234");
document.getElementById("focusme").focus();
}