make absURLs more resilient (trailing slashes/not)

This commit is contained in:
jake committed 2020-02-03 08:58:30 -05:00
1 parent af61020152
commit f19084006f
10 files changed
+17 -15

No files matched your search

+3 -3
View File
@@ -12,7 +12,7 @@
"description": {{ with .Description }}{{ . }}{{ else }}{{ .Site.Params.description }}{{ end }},
"wordCount": "{{ .WordCount }}",
"author": {
"@id": {{ printf "%s%s" .Site.BaseURL "#author" }}
"@id": {{ path.Join $.Site.BaseURL "#author" }}
},
"publisher": {
"@type": "Organization",
@@ -20,14 +20,14 @@
"url": {{ .Site.BaseURL }},
"logo": {
"@type": "ImageObject",
"url": {{ .Scratch.Get "logoImage_url" }},
"url": {{ .Scratch.Get "logoImage_url" | absURL }},
"width": "{{ .Scratch.Get "logoImage_width" }}",
"height": "{{ .Scratch.Get "logoImage_height" }}"
}
},
"image": {
"@type": "ImageObject",
"url": {{ .Scratch.Get "socialImage_url" }},
"url": {{ .Scratch.Get "socialImage_url" | absURL }},
"width": "{{ .Scratch.Get "socialImage_width" }}",
"height": "{{ .Scratch.Get "socialImage_height" }}"
}