Branch: master
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
20 lines (14 sloc) 494 Bytes
title signature
npm install moment-timer

This is a Moment.js plugin that allows the use of timers, which offer much more control than the native JavaScript timers. It's basically a rewrite of JavaScripts own setInterval and setTimeout.

For example,

var timer = moment.duration(5, "seconds").timer({loop: true}, function() {
  // Callback

The repository is located at