diff options
| author | Aditya Telange <21258296+adityatelange@users.noreply.github.com> | 2020-10-12 17:26:45 +0530 |
|---|---|---|
| committer | Aditya Telange <21258296+adityatelange@users.noreply.github.com> | 2020-10-12 17:26:45 +0530 |
| commit | 23636ab3260ea41354d7ee560f8848e1c684ec6d (patch) | |
| tree | 1ba42f92b24215ef0c50bf42233f8c5890b23e58 /layouts/partials/templates/opengraph.html | |
| parent | 306889f68bcbaae0789bc9dc4c5578c2ddc348af (diff) | |
templates: social-meta: prefer cover image over other images
Diffstat (limited to 'layouts/partials/templates/opengraph.html')
| -rw-r--r-- | layouts/partials/templates/opengraph.html | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/layouts/partials/templates/opengraph.html b/layouts/partials/templates/opengraph.html index 48ad5eb..834e3a1 100644 --- a/layouts/partials/templates/opengraph.html +++ b/layouts/partials/templates/opengraph.html @@ -8,7 +8,7 @@ {{- else}} <meta property="og:image" content="{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }}" /> {{- end}} -{{- end }} +{{- else }} {{ with $.Params.images }}{{ range first 6 . -}} <meta property="og:image" content="{{ . | absURL }}" /> {{ end }}{{ else -}} @@ -21,6 +21,7 @@ {{- with $.Site.Params.images -}} <meta property="og:image" content="{{ index . 0 | absURL }}"/> {{ end }}{{ end }}{{ end }} +{{- end }} {{- $iso8601 := "2006-01-02T15:04:05-07:00" -}} {{- if .IsPage }} |
