Img source: timeanddate.com

It is hard to think about a project where you do not have dates and timestamps involved in it. You may need to find the day when a user has performed a particular action, or when an event has occurred and many other cases. TimeDifference is a really helpful gem that makes it really easy to calculate the difference between two time periods. It allows you to calculate the difference in years, months, weeks, days, hours, minutes and seconds.

Continue reading