JSFiddle - React, Tailwind, and code Playground

HTML

<div id='countdown'>60</div>

JavaScript

$(function() {
        var cd = $('#countdown');
        var c = parseInt(cd.text(),10);
        var interv = setInterval(function() {
            c--;
            cd.html(c);
            if (c == 0) {
                window.location.reload(false);
                clearInterval(interv);
            }
        }, 1000);
    });