react-stopwatch icon indicating copy to clipboard operation
react-stopwatch copied to clipboard

Relying on setInterval

Open DavidRHulme opened this issue 7 years ago • 2 comments

From a metronome app I wrote, I don't think you can rely on setInterval for timing if you want it to be precise. Over time it will drift. Use can use something like performance.now() instead.

DavidRHulme avatar Apr 06 '18 10:04 DavidRHulme

Agree. It is a Google Audit suggested method, described here: https://developers.google.com/web/tools/lighthouse/audits/date-now

nermand avatar Apr 06 '18 15:04 nermand

yes, I agree too. I will take a look at this in the next version.

saeta-eth avatar Apr 09 '18 21:04 saeta-eth