Open qinidea opened 10 years ago
We recently had a need for this in one of our projects as well! My only concern is with phrasing.
Would the equivalent of "5 minutes until" work well in Chinese?
So glad to hear you need it too! Yes it works pretty well in Chinese!
i also have the need for something like "in x minutes". using timeAgo doesn't work (obviously).
(lldb) po arrivalTime
2014-10-29 11:48:00 +0000
(lldb) po [NSDate date]
2014-10-29 11:46:48 +0000
(lldb) po arrivalTime.timeAgoSinceNow
A minute ago
There is a set of methods that you can build logic around, if internationalization is not required. These are the "timeUntil" methods that return numbers.
Unfortunately, entirely new translations would be required to create "in x minutes". Would you like me to work on a structure for it? Of course there will be very few translations in the beginning.
i'm going to create it myself, no problem here. since the translations are very specific, i think its a better practise to just use the "timeUntil" methods
Hi I am the maintainer of GitHub CoreDataUtility and OSX LogRabbit for Android. I am adding "TimeAgo" as possible rendered date format. While testing I found that only dates from the past and present are supported. Due to the nature of CoreDataUtilty I need to handle all ranges of dates (future, present and past).
First question is has someone already added support for this and I am missing it?
If not would it be OK if I add this to "TimeAgo". The name is not perfect but I don't think there should be separate method based on the tense of the date. Or I could make a new method that is "FuzzyDate" that includes "TimeAgo" and "TimeUntil" functionality.
My biggest concern, if I implement this, is the localization. It's not that important for my utility but is very important for this library.
+1, I'd really like to see this.
It would be great to have such a method
+1
👍
+1
+1
+1
I'm developing a Timer app and I need display something like "It will run in 5 minutes". In android I can use DateUtils.getRelativeTimeSpanString and it works fine. But in iOS I cannot find any solution. Actually I can write my own codes, but the most difficulty is localization. "Time Ago" is perfect for many(maybe most) projects, but it's not enough for me... Btw I can contribute Chinese localization.