diff options
author | Dan Ho <igaryhe@gmail.com> | 2019-09-08 16:27:52 +0300 |
---|---|---|
committer | Track3 <34504964+Track3@users.noreply.github.com> | 2019-09-08 16:27:52 +0300 |
commit | 3f7461d95d107895b359fbe910aebde666ed01fc (patch) | |
tree | ecfa1de67fa61ee6614b68d007b82cde89a20ece | |
parent | 16c9d78ae518aebb65c3bca5871b2550bbabca16 (diff) |
Add post author display (#91)
Add the ability to display post author set with `author` param in the content's front matter.
-rw-r--r-- | layouts/posts/single.html | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/layouts/posts/single.html b/layouts/posts/single.html index 53c0818..371de79 100644 --- a/layouts/posts/single.html +++ b/layouts/posts/single.html @@ -30,6 +30,9 @@ {{- end }} <hr class="post-end"> <footer class="post-info"> + {{- with $.Param "author" }} + <p><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-feather"><path d="M20.24 12.24a6 6 0 0 0-8.49-8.49L5 10.5V19h8.5z"></path><line x1="16" y1="8" x2="2" y2="22"></line><line x1="17.5" y1="15" x2="9" y2="15"></line></svg>{{ . }}</p> + {{- end }} {{- with .Params.tags }} <p> <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-tag meta-icon"><path d="M20.59 13.41l-7.17 7.17a2 2 0 0 1-2.83 0L2 12V2h10l8.59 8.59a2 2 0 0 1 0 2.82z"></path><line x1="7" y1="7" x2="7" y2="7"></line></svg> |