JSFiddle - React, Tailwind, and code Playground
HTML
<label>
<input type='checkbox' checked="checked" />
CLICK ME....
</label>
JavaScript
$("label").on("click",function(e){
if($(this).find(":checkbox").prop("checked"))
{
alert("checked now...now make it unchecked");
$(this) .children("input[type='checkbox']").prop("checked",false);
}
else{
alert("not checked");
$(this) .children("input[type='checkbox']").prop("checked",true);
}
e.preventDefault();
});