t-d
v0.0.2
Published
Get a time in the past or future based off the current time.
Downloads
5
Readme
t-d
Currently under development.
Get a time in the past or future based off the current time. Supports function chaining for a clean, human-readable time offset (time delta).
Currently supports weeks, days, and seconds.
Installation
npm install --save t-d
Usage
Proposed API:
var td = require('t-d');
// Time for three days and four minutes from now:
td().days(3).minutes(4).fromNow();
// Time for six weeks, two days, and 68 seconds ago:
td().weeks(6).days(2).seconds(68).ago();
License
MIT
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
Crafted with <3 by John Otander (@4lpine).
This package was initially generated with yeoman and the p generator.