JSFiddle - React, Tailwind, and code Playground
HTML
<select id="select1" onchange="findIndex()">
<option>I</option>
<option>Love</option>
<option>my</option>
<option>granny</option>
</select>
JavaScript
function findIndex() {
var e = document.getElementById("select1");
alert(e.selectedIndex);
}