JSFiddle - React, Tailwind, and code Playground

HTML

<select name="CCards">
<option value="0">Select Saved Payment Method:</option>
<option value="1846">test  xxxx1234</option>
<option value="1962">test2  xxxx3456</option>
</select>

JavaScript

$('select').change(function(){
    alert($('option:selected',$(this)).index()); 
});