JSFiddle - React, Tailwind, and code Playground
by tikosar
HTML
<div id="log"></div>
JavaScript
const log = () => {
const timePerf = Math.round((performance.now() - startTimePerf) / 1000);
const timeDate = Math.round((Date.now() - startTimeDate) / 1000);
document.querySelector('#log').insertAdjacentHTML('beforeend', `<div>performance: ${timePerf}s, date: ${timeDate}s</div>`);
};
const startTimePerf = performance.now();
const startTimeDate = Date.now();
log();
setInterval(log, 10000);