mirror of
https://github.com/alanorth/hugo-theme-bootstrap4-blog.git
synced 2025-05-10 22:46:02 +02:00
layouts: Remove quoting of structured data
I don't understand it, but quoting these values causes Hugo to use escape codes for non-ASCII (?) characters. For example: "description": "A thriving oasis in Jordan\x27s desert is at risk of disappearing." Google's Search Console shows the following error: Unparsable structured data > Bad escape sequence in string We had a similar issue with dates that was fixed in #111 and the solution is the same here.
This commit is contained in:
@ -38,12 +38,12 @@
|
||||
}
|
||||
{{- if or (.Params.keywords) (or (.Params.categories) (.Params.tags)) -}}
|
||||
,
|
||||
"keywords": "{{ delimit (union .Params.keywords (union .Params.categories .Params.tags)) ", " }}"
|
||||
"keywords": {{ delimit (union .Params.keywords (union .Params.categories .Params.tags)) ", " }}
|
||||
{{- end }}
|
||||
|
||||
{{- with .Params.description -}}
|
||||
,
|
||||
"description": "{{ . }}"
|
||||
"description": {{ . }}
|
||||
{{- end }}
|
||||
}
|
||||
</script>
|
||||
|
Reference in New Issue
Block a user