@dnode/parse-duration
v1.4.7
Published
[![dependencies | 1 | 1](https://img.shields.io/badge/dependencies-1%20|%201-blue.svg)](DEPENDENCIES.md)
Downloads
32
Readme
DEPRECATED
In favor of @dnode/duration
Usage
1 hour 20 minutes in milliseconds
const ms = require('@dnode/parse-duration')('1h 20m');
1 hour 20 minutes in seconds (with second parameter)
const s = require('@dnode/parse-duration')('1h 20m', 's');
1 hour 20 minutes in seconds (with "in" keyword)
const s = require('@dnode/parse-duration')('1h 20m in s');