+ New og:thumbnail mechanism for pages

Use the image field to specify a custom image for embeds
This commit is contained in:
shockrah 2021-09-19 21:02:21 -07:00
parent 46b3141611
commit cfb301fbfd
3 changed files with 9 additions and 1 deletions

BIN
content/media/thumbnails/dragon-soda.jpg (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -4,6 +4,7 @@ date: 2021-09-19
draft: false
description: Afterthoughts on making two random drinks
category: article
image: "/media/img/thumbs/dragon-soda.jpg"
---
## Preface

View File

@ -15,5 +15,9 @@
{{ if .IsHome }}{{ $desc = .Params.Description }}{{end}}
<meta property="og:description" content="{{ $desc }}">
<meta property="og:type" content="website">
<meta property="og:image" content="/favicon.png">
{{ $ogimage := "/favicon.png" }}
{{ if .Params.Image }}
{{ $ogimage = .Params.Image }}
{{ end }}
<meta property="og:image" content="{{ $ogimage }}">
</head>