0.0.3 • Published 6 years ago

timerow v0.0.3

Weekly downloads
5
License
ISC
Repository
github
Last release
6 years ago

timerow

A simple node module created for those who want to replay the data order.

Installation

npm i timerow

Usage example

const TimeRow = require('timerow');
const example = new TimeRow();

example.add('Welcome back, Jim!');
setTimeout(() => {
  example.add('<3');
  example.replay(data => {
    console.log(data);
  });
}, 2000);

Methods

row.add(data) // Add data to TimeRow
row.getJSON() // Get TimeRow object as JSON
row.get() // Get TimeRow object as JavaScript object
row.replayData({options}, data, callback(data)) // Replay TimeRow object with options
row.replayJSON(json, callback(data)) // Replay TimeRow JSON
row.replay(callback(data)) // Replay current TimeRow object
row.speedReplay(modifier, callback(data)) // Replay current TimeRow object with modified speed(-2: 2 times slower; 3: 3 times faster)