Closed toutpt closed 9 years ago
OK, after reading the code I need to pass halfUnit in the option. I believe it should be false by default.
humanizeDuration(moment.duration({hours: 1.5}).asMilliseconds(), { halfUnit: false, language: 'fr' }); "1 heure, 30 minutes"
I let you close the issue.
A future version of HumanizeDuration may set halfUnit
to false
by default or remove it entirely, but not yet.
Closing this issue.
With 1.6 hours I have a good result:
humanizeDuration(moment.duration({hours: 1.6}).asMilliseconds(), { language: 'fr' }); "1 heure, 36 minutes"
But with 1.5 I have something bad: humanizeDuration(moment.duration({hours: 1.5}).asMilliseconds(), { language: 'fr' }); "1.5 heures"
Expected result is : "1 heure, 30 minutes"