feat(app/utils, plugins): normalize dates with improved format (#573)

This commit is contained in:
Simon Lecoq
2021-10-13 22:08:31 -04:00
committed by GitHub
parent 19036b2e41
commit 662fe8de2f
16 changed files with 32 additions and 16 deletions

View File

@@ -19,7 +19,7 @@
<td>
<%= description %>
<br>
<i>Published on <%= f.date(new Date(date), {dateStyle:"short", timeZone:config.timezone?.name}) %></i>
<i>Published on <%= f.date(new Date(date), {date:true, timeZone:config.timezone?.name}) %></i>
</td>
</tr>
</table>
@@ -27,7 +27,7 @@
<%_ } else if (plugins.posts.list.length) { _%>
<%_ for (const {title, date, link} of plugins.posts.list) { _%>
* [<%= title.trim() %>](<%= link %>)
* *Published on <%= f.date(new Date(date), {dateStyle:"short", timeZone:config.timezone?.name}) %>*
* *Published on <%= f.date(new Date(date), {date:true, timeZone:config.timezone?.name}) %>*
<%_ } _%>
<%_ } else { _%>
No recent posts