@lukekarrys/score-watcher
Score watcher for brakcet.club.
Last updated 2 years ago by lukekarrys .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @lukekarrys/score-watcher 
SYNC missed versions from official npm registry.

score-watcher

Greenkeeper badge Build Status

Score watcher for bracket.club.

Usage

const ScoreWatcher = require('score-watcher');

new ScoreWatcher({
    // Required
    sport: 'ncaam',
    year: '2015',
    // An optional bracket to initialize the updater with
    // Will default to an empty bracket for the sport/year
    master: '',
    // Optional log file
    logger: null,
    // The callbacks
    onSave: function (master, cb) {
        // Will be called with each master as a string
        // `cb` is optional but should be used to ensure
        // that each bracket is saved before moving to
        // the next one
    },
    scores: {
        // Config for scores module
        interval: '1m',
        url: 'http://url.com'
    }
}).start();

What is it doing?

It is setting up an async.queue and creating a watcher/emitter with scores. Then every time the queue drains, it calls onSave with the latest master (and an optional callback to notify the watcher when it has been added).

Is it on npm?

Yeah, now that there are publically scoped modules it's at npm install @lukekarrys/score-watcher.

LICENSE

MIT

Current Tags

  • 5.2.4                                ...           latest (2 years ago)

14 Versions

  • 5.2.4                                ...           2 years ago
  • 5.2.3                                ...           2 years ago
  • 5.2.2                                ...           3 years ago
  • 5.2.1                                ...           3 years ago
  • 5.2.0                                ...           4 years ago
  • 5.1.0                                ...           4 years ago
  • 5.0.4                                ...           4 years ago
  • 5.0.3                                ...           4 years ago
  • 5.0.2                                ...           4 years ago
  • 5.0.1                                ...           4 years ago
  • 5.0.0                                ...           4 years ago
  • 4.0.0                                ...           4 years ago
  • 3.0.1                                ...           4 years ago
  • 3.0.0                                ...           4 years ago
Maintainers (1)
Downloads
Today 0
This Week 1
This Month 1
Last Day 0
Last Week 0
Last Month 0
Dependencies (6)
Dev Dependencies (5)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |