6f8c929898
Also introduces a local time helper that we can use to format dates and times.
6 lines
181 B
Ruby
6 lines
181 B
Ruby
module TimeHelper
|
|
def local_datetime_tag(datetime, style: :time, **attributes)
|
|
tag.time **attributes, datetime: datetime.iso8601, data: { local_time_target: style }
|
|
end
|
|
end
|