0.1.0 • Published 7 years ago
@mblackmblack/to-seconds v0.1.0
to-seconds 
Convert an object of time properties to seconds:
{seconds: 2}→120
Install
$ npm install @mblackmblack/to-secondsUsage
const toSeconds = require('@mblackmblack/to-seconds');
toSeconds({
days: 15,
hours: 11,
minutes: 23,
seconds: 1
});
//=> 1336981API
toSeconds(input)
input
Type: Object
Specify an object with any of the following properties:
dayshoursminutesseconds
Related
- to-milliseconds - The inverse of this module
- parse-ms - The inverse of this module
- pretty-ms - Convert milliseconds to a human readable string
Credits
This project is forked from https://github.com/sindresorhus/to-milliseconds. Special thanks to sindresorhus
License
MIT © Matthew Black
0.1.0
7 years ago