1386

Given a specific DateTime value, how do I display relative time, like:

  • 2 hours ago
  • 3 days ago
  • a month ago


  • What if you want to calculate a relative time from now to Future? - Jhonny D. Cano -Leftware-
  • moment.js is a very nice date parsing library.. You can consider using that (server side or client side), depending on your needs. just fyi because nobody mentioned it here - code ninja
  • There is the .net package github.com/NickStrupat/TimeAgo which pretty much does what is being asked. - Rossco

Linked


Related

Latest