Skip to content
This repository has been archived by the owner on Mar 19, 2022. It is now read-only.

Latest commit

 

History

History
24 lines (21 loc) · 570 Bytes

README.md

File metadata and controls

24 lines (21 loc) · 570 Bytes

Three-Fourteen

Three-Fourteen is a simple in-memory function scheduler.

const { initialize } = require('three-fourteen');
initialize([
  { action: () => console.log('Runs every minute') },
  {
    action: () => console.log('Runs on the 15th minute of every hour'),
    schedule: { minute: 15 }
  },
  {
    action: () => console.log('Runs at 3:14 every night'),
    schedule: { hour: 3, minute: 14 }
  },
  {
    action: () => console.log('Runs on the first minute of July'),
    schedule: { month: 5 }
  }
]);

Check the index.d.ts for more typing stuff.