Hardcoding img paths for twitter and meta

This commit is contained in:
shockrah 2023-10-07 15:59:45 -07:00
parent 75bbb538a6
commit 970e41e4e4

View File

@ -16,9 +16,10 @@
<meta property="og:url" content="{{ .Permalink }}"> <meta property="og:url" content="{{ .Permalink }}">
<meta property="og:type" content="website"> <meta property="og:type" content="website">
{{ if .Params.Thumbnail }} {{ if .Params.Thumbnail }}
<meta property="og:image" content="{{ .Params.Thumbnail }}"> <meta property="og:image" content="https://temper.tv{{ .Params.Thumbnail }}">
{{ else }} {{ else }}
<meta property="og:image" content="/img/bg.png"> {{- /* Hard coding this because baseURL is super delicate */ -}}
<meta property="og:image" content="https://temper.tv/img/bg.png">
{{ end }} {{ end }}
{{- /* Twitter meta tags */ -}} {{- /* Twitter meta tags */ -}}
@ -26,9 +27,10 @@
<meta name="twitter:description" content="{{ default .Site.Params.Description .Params.Description }}"> <meta name="twitter:description" content="{{ default .Site.Params.Description .Params.Description }}">
<meta property="twitter:url" content="{{ .Permalink }}"> <meta property="twitter:url" content="{{ .Permalink }}">
{{ if .Params.Thumbnail }} {{ if .Params.Thumbnail }}
<meta property="twitter:image" content="{{ .Params.Thumbnail }}"> {{- /* Hard coding this because baseURL is super delicate */ -}}
<meta property="twitter:image" content="https://temper.tv{{ .Params.Thumbnail }}">
{{ else }} {{ else }}
<meta property="twitter:image" content="/img/bg.png"> <meta property="twitter:image" content="{{ .Site.BaseURL }}img/bg.png">
{{ end }} {{ end }}
{{- /* Requirements special to twitter, just don't touch these tbh */ -}} {{- /* Requirements special to twitter, just don't touch these tbh */ -}}
{{- /* https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/summary-card-with-large-image */ -}} {{- /* https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/summary-card-with-large-image */ -}}