Skip to content

Commit

Permalink
Show the last modified date of posts (jekyll#432)
Browse files Browse the repository at this point in the history
Merge pull request 432
  • Loading branch information
hszhakka authored and jekyllbot committed Jan 24, 2020
1 parent 4e838ff commit 49cb5f4
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,16 @@
<header class="post-header">
<h1 class="post-title p-name" itemprop="name headline">{{ page.title | escape }}</h1>
<p class="post-meta">
{%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%}
<time class="dt-published" datetime="{{ page.date | date_to_xmlschema }}" itemprop="datePublished">
{%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%}
{{ page.date | date: date_format }}
</time>
{%- if page.modified_date -%}
~
<time class="dt-modified" datetime="{{ page.modified_date | date_to_xmlschema }}" itemprop="dateModified">
{{ page.modified_date | date: date_format }}
</time>
{%- endif -%}
{%- if page.author -%}
• {% for author in page.author %}
<span itemprop="author" itemscope itemtype="http://schema.org/Person">
Expand Down

0 comments on commit 49cb5f4

Please sign in to comment.