Declarative setInterval
JavaScript
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.gitignore
.npmignore
README.md
index.js
package.json
test.js

README.md

every-time

Declarative setInterval. See also: after-time

every = require('every-time')

every('5 mins, 5 seconds', function(){
  console.log('hello')
})

Full Language Reference: english-time

Install

$ npm install every-time

Usage

every = require('every-time')

every('1s 250ms', function(){
  // do something
})

Passing parameters:

every('5 secs', 'foo', 'bar', function(foo, bar) {

  foo
  // => 'foo'

  bar
  // => 'bar'

})