JSFiddle - React, Tailwind, and code Playground

by Vijaykumar Kagne

HTML

<body bgcolor=”white” onload=”fs()”>
<div align=”center”>
<span id=”countdown” style=”background-color:blue;font-size:380px;”></span></div>
</body>

JavaScript

function fs(){
var d=new Date();
var hh=d.getHours();
var mm=d.getMinutes();
var ss=d.getSeconds();

document.getElementById(“countdown”).innerHTML=hh+”:”+mm+”:”+ss;

setTimeout(“fs()”, 1000);

}