Skip to main content

Stopwatch

Use elapsedMilliseconds for active elapsed time. It is independent from clock formatting.

StopwatchLive

Stopwatch

0.0s
idle
Elapsed0ms
Tick0
Generationnot started
const timer = useTimer({ updateIntervalMs: 100 });
const seconds = Math.floor(timer.elapsedMilliseconds / 1000);