js-clock

Human-readable timer

Usage no npm install needed!

<script type="module">
  import jsClock from 'https://cdn.skypack.dev/js-clock';
</script>

README

A human-readable timer

var clock = new Clock();

clock.setInterval('1h 10m 15s 300ms');
clock.setTicker(function() {
    // ...
});

clock.start();

// stops the ticker
clock.stop();