I need to show natural dates like
Is there something built into the rails? Or maybe a third party? It is not difficult to implement, but I do not want to reinvent the wheel.
I think you are looking time_ago_in_words
time_ago_in_words
An interesting approach to consider is converting time to word on the client side using javascript. This may cause your pages to be cached, but at the same time they will apply to end users.
Darragh Curran javascript , Rails.
, .
Also check for chronic stone
http://chronic.rubyforge.org/
Source: https://habr.com/ru/post/1713796/More articles:MySQL INSERT / UPDATE without DUPLICATE key - mysqlasp mvc with relentlessness? - asp.net-mvcУказание внешнего ключа делает его индексом? - sqlCan I stop IIS? - c #Best practice for applying domain design in .NET? - c #iPhone Contact Picker (as in Mail.app) - objective-cIPhone application crashes using mach_msg_trap in UIWebView using specific URL - objective-cHow to limit the version of a third-party package dependency link? - maven-2What Rails plugins should I use? - ruby-on-railsCreate or replace a role? - sqlAll Articles