next-time

Returns the nearest date of given time

npm install next-time
2 downloads in the last week
9 downloads in the last month

next-time

Returns the nearest date of given time

Install

$ npm install next-time

Usage

At 6:00:


now
// => 20:30

nextTime('23')
// => Date { Today 23:30 }

nextTime('7:20')
// => Date { Tomorrow 7:20 }

npm loves you