diff options
author | Alex Shpak <alex-shpak@users.noreply.github.com> | 2021-05-03 21:47:19 +0200 |
---|---|---|
committer | Alex Shpak <alex-shpak@users.noreply.github.com> | 2021-05-03 21:47:19 +0200 |
commit | c197f3399b0aee698afc5278dbb33506892311ef (patch) | |
tree | 0ab46c0cfdfdaf28e77e038cc41c80c144c1d3e7 /layouts/partials/docs/post-meta.html | |
parent | e0823c213882489bb4ee3959bf2b306061762bf1 (diff) |
#286, Add ability to set image for posts
Diffstat (limited to 'layouts/partials/docs/post-meta.html')
-rw-r--r-- | layouts/partials/docs/post-meta.html | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/layouts/partials/docs/post-meta.html b/layouts/partials/docs/post-meta.html index c56a528..527431a 100644 --- a/layouts/partials/docs/post-meta.html +++ b/layouts/partials/docs/post-meta.html @@ -11,3 +11,13 @@ </div> {{ end }} {{ end }} + +<p> +{{ if .Params.image}} + {{ with .Resources.GetMatch .Params.image }} + <img src={{ .RelPermalink }} /> + {{ else }} + <img src={{ .Params.image | relURL }} /> + {{ end }} +{{ end }} +</p> |