Skip to content

Commit

Permalink
Show post date instead of read time
Browse files Browse the repository at this point in the history
  • Loading branch information
iBug committed Nov 20, 2019
1 parent e9ac549 commit de736bd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,7 @@ defaults:
type: posts
values:
read_time: true
show_date: true
related: true
toc: true
#toc_label: "On this page"
Expand Down Expand Up @@ -387,6 +388,7 @@ defaults:
lang: "zh-CN"
locale: "zh-CN"
read_time: true
show_date: true
comments: true
words_per_minute: 350
sidebar:
Expand Down
4 changes: 3 additions & 1 deletion _includes/page__hero.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ <h1 id="page-title" class="page__title" itemprop="headline">
{% elsif page.header.show_overlay_excerpt != false and page.excerpt %}
<p class="page__lead">{{ page.excerpt | markdownify | remove: "<p>" | remove: "</p>" }}</p>
{% endif %}
{% if page.read_time %}
{% if page.show_date %}
<p class="page__meta"><i class="far fa-calendar-alt" aria-hidden="true"></i> {{ page.date | date: '%B %d, %Y' }}</p>
{% elsif page.read_time %}
<p class="page__meta"><i class="far fa-clock" aria-hidden="true"></i> {% include read-time.html %}</p>
{% endif %}
{% if page.header.cta_url %}
Expand Down

0 comments on commit de736bd

Please sign in to comment.