Add author field to blog (#322)

* Add author field

* Check if author exists
This commit is contained in:
Alex Beattie 2022-02-21 12:08:45 -06:00 committed by GitHub
parent fade059bf5
commit c88d3a359d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,6 +9,11 @@
<h2 class="title is-1 top-pad strong-post-title">
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
</h2>
{{ if .Params.author }}
<h4 class="title is-4">
By {{ .Params.author | markdownify }}
</h4>
{{ end }}
<div class="post-data">
{{ if .Params.date }}{{ .Date.Format (.Site.Params.dateFormat | default ":date_medium") }}{{ end }}
{{ if .Site.Params.showReadingTime | default true }}