Sha256: 97813e249ed121cad096dc641b0a7ceb2c69139c77b9b0dbea03ea74241f5ccf

Contents?: true

Size: 288 Bytes

Versions: 10

Compression:

Stored size: 288 Bytes

Contents

module TimeHelper
  def friendly_time(time, t_key = nil)
    friendly_time = time_ago_in_words time
    friendly_time_t = t_key ? t(t_key, time: friendly_time) : friendly_time

    <<~HTML.html_safe
      <time title="#{time}">
        #{friendly_time_t}
      </time>
    HTML
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
mumuki-laboratory-9.23.0 app/helpers/time_helper.rb
mumuki-laboratory-9.22.0 app/helpers/time_helper.rb
mumuki-laboratory-9.21.0 app/helpers/time_helper.rb
mumuki-laboratory-9.20.1 app/helpers/time_helper.rb
mumuki-laboratory-9.20.0 app/helpers/time_helper.rb
mumuki-laboratory-9.19.0 app/helpers/time_helper.rb
mumuki-laboratory-9.18.1 app/helpers/time_helper.rb
mumuki-laboratory-9.18.0 app/helpers/time_helper.rb
mumuki-laboratory-9.17.0 app/helpers/time_helper.rb
mumuki-laboratory-9.16.0 app/helpers/time_helper.rb