JSFiddle - React, Tailwind, and code Playground

HTML

<div id="countdown"></div>

JavaScript

function ShowTime() 
        {
            var now = new Date();
            var hrs = 15-now.getHours();
            var mins = 60-now.getMinutes();
            var secs = 60-now.getSeconds();
            timeLeft = "" +hrs+' hours '+mins+' minutes '+secs+' seconds';
            $("#countdown").html(timeLeft);
        }

        var countdown;
        function StopTime() 
        {
            clearInterval(countdown);   
        }

        ShowTime();
        var countdown = setInterval(ShowTime ,1000);