JSFiddle - React, Tailwind, and code Playground

HTML

<div>
    <input type="radio" name="fruit" value="orange" id="orange" checked="checked">
    <input type="radio" name="fruit" value="apple" id="apple">
    <input type="radio" name="fruit" value="banana" id="banana">    
    <label for="apple">apple</label>    
    <label for="orange">orange</label>
    <label for="banana">banana</label> 
 </div>

JavaScript

$inputs = $('input');

setInterval(function(){

    $next = $inputs.filter(":checked").next('input');

    if ($next.length) $next.prop('checked', true);
    else $inputs.first().prop('checked', true);


}, 3000);