JSFiddle - React, Tailwind, and code Playground

by HemalathaThanigaivel

HTML

<input  type="radio" name="things" value="exam" />  exam
<input  type="radio" name="things" value="journey" />journey

JavaScript

/* var prev = {};
$("input[name=things]").click(function(){
    if (prev && prev.value == this.value) {
    console.log("here")
        $(this).prop('checked', !prev.status);
    }
    prev = {
        value: this.value,
        status: this.checked
    };
});
 */