JSFiddle - React, Tailwind, and code Playground

HTML

<div id="timestamp">0</div>

JavaScript

var timestamp=0;

var timerId = setInterval(function() {
  timestamp=timestamp+1;

  document.getElementById('timestamp').innerHTML=new Date(timestamp)+"||||"+timestamp;
}, 1000);