1.0.1 • Published 8 years ago

convert-seconds v1.0.1

Weekly downloads
760
License
MIT
Repository
github
Last release
8 years ago

convert-seconds

Convert seconds to hours, minutes, seconds

Build Status

Install

$ npm install --save convert-seconds

Usage

Pass in seconds (as a number or string), and get an object in return:

var convert = require('convert-seconds');

convert(3661);
// => { hours: 1, minutes: 1, seconds: 1 }

convert(3661).hours;
// => 1

convert('3661').minutes;
// => 1

convert(3661).seconds;
// => 1

License

MIT @ Michael Wuergler