JSFiddle - React, Tailwind, and code Playground
HTML
<div>
<a>this is a</a>
<button>
hey this button1
</button>
<button class='myclass'>
hey this button2
</button>
<button class='myclass'>
hey this button3 with myclass
</button>
</div>
JavaScript
var elems = document.querySelectorAll('div');
var button = elems[0].querySelectorAll('button');
alert(button[0].innerText+" : "+button[1].innerText+" : "+button[2].className);