Refactor DateTime and TimeSpan humanization to use ToQuantityExtensions.ToQuantity to quantify time units
Brought over from #192
Hi, I am actually working on this and I have doubts about the need. This is what I understood: the aim is to restructure humanization of Datetime to have the same parameters as there in ToQuantity( like ShowQuantityAs.Words). Is that correct? Thanks
Partially covered by #405
@alimeziane not exactly. The idea was to use Inflector for words as "second", "minute", "hour", etc.
@hazzik , In the PR #405 , i added the parameter "ShowQuantityAs" to TimeSpan and DateTime humanization , it will select the display mode (numbers or words), for example : TimeSpan.FromDays(15).Humanize(2,showQuantityAs : ShowQuantityAs.Words) --> two weeks , one day DateTime.Now.AddDays(12).Humanize(false,showQuantityAs : ShowQuantityAs.Words) --> twelve days from now
So I think it solves the #290 issue , but I do not see anything added to solve the current issue. If you have an example that would be cool.
So I think it solves the #290 issue , but I do not see anything added to solve the current issue. If you have an example that would be cool.
You're right.
This issue is about internal implementation of time fraction quantification, to remove need of resources
@MehdiK still think this is worthwhile?