EvanHahn / HumanizeDuration.js

361000 becomes "6 minutes, 1 second"
https://evanhahn.github.io/HumanizeDuration.js/
The Unlicense
1.65k stars 175 forks source link

Add a ceil helper to round to the next biggest integer #162

Closed anz000 closed 5 years ago

anz000 commented 5 years ago

I'm currently using round like humanizeDuration( 120.1, { units: ['m'] , round: true })

Currently it returns 2 mins, I'd want 3 mins using a ceiling function. How difficult is it to add a ceil (similar to round) but that always rounds to the next integer?

Thanks.

EvanHahn commented 5 years ago

That's a good idea, but because this library is in maintenance mode (see the blurb in the readme), I won't be able to add this feature. Going to close this issue for that reason.

I'm happy to endorse a fork that adds this, though!