JSFiddle - React, Tailwind, and code Playground
HTML
<input name="gender" type='radio' id='rdoMale'>Male
<input name="gender" type='radio' id='rdoFemale'>Female
<button id="btnGenderStatus">Click me</button>
JavaScript
var rdM=$("#rdoMale");
var rdF=$("#rdoFemale");
$("#btnGenderStatus").on('click',function(){
if($(rdM).is(":checked"))
{
console.log("You selected Male");
}
else if ($(rdF).is(":checked"))
{console.log("You selected female");}
});