mirror of
				https://github.com/Wonderfall/hugo-WonderMod.git
				synced 2025-10-31 03:45:24 +01:00 
			
		
		
		
	templates: add cover image to be linked into meta
for opengraph, schema and twitter
This commit is contained in:
		| @@ -2,6 +2,13 @@ | ||||
| <meta property="og:description" content="{{ with .Description }}{{ . }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end }}" /> | ||||
| <meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" /> | ||||
| <meta property="og:url" content="{{ .Permalink }}" /> | ||||
| {{- if .Params.cover.image -}} | ||||
| {{- if (ne .Params.cover.relative true) }} | ||||
| <meta property="og:image" content="{{ .Params.cover.image | absURL }}" /> | ||||
| {{- else}} | ||||
| <meta property="og:image" content="{{ (path.Join .RelPermalink .Params.cover.image ) | absURL }}" /> | ||||
| {{- end}} | ||||
| {{- end }} | ||||
| {{ with $.Params.images }}{{ range first 6 . -}} | ||||
| <meta property="og:image" content="{{ . | absURL }}" /> | ||||
| {{ end }}{{ else -}} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Aditya Telange
					Aditya Telange