How can I format a date in Objective-C similar to the jquery.timeago library?

前端 未结 9 2012
说谎
说谎 2020-12-29 05:57

I have a feed of items displayed in table cells, part of which is a date / timestamp in the past.

In Objective-C, how can I accomplish formatting them in the same m

9条回答
  •  无人及你
    2020-12-29 06:35

    You can try with NSDateFormater and write it your self.

    If value is under one minute then write just now, otherwise minutes, hours, days, etc.

提交回复
热议问题