From 64149de7b6e41482cbcbf9823d3252bb2d9962fd Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Wed, 14 Oct 2020 22:57:31 +0530 Subject: [PATCH] json-schema: add more params --- layouts/partials/templates/schema_json.html | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/layouts/partials/templates/schema_json.html b/layouts/partials/templates/schema_json.html index 3dabd683..82182708 100644 --- a/layouts/partials/templates/schema_json.html +++ b/layouts/partials/templates/schema_json.html @@ -3,8 +3,10 @@ { "@context": "https://schema.org", "@type": "{{- ( .Site.Params.schema.publisherType | default "Organization") | humanize -}}", - "name": {{ .Site.Params.title }}, + "name": {{ .Site.Title }}, "url": {{ .Site.BaseURL }}, + "description": {{ .Site.Params.description | plainify | safeHTML }}, + "thumbnailUrl": {{ .Site.Params.assets.favicon | default "favicon.ico" | absURL }}, "sameAs": [ {{- if .Site.Params.schema.sameAs }} {{ range $i, $e := .Site.Params.schema.sameAs }}{{ if $i }}, {{ end }}{{ $e }}{{ end }} @@ -29,6 +31,8 @@ {{ range $i, $e := .Params.tags }}{{ if $i }}, {{ end }}{{ $e }}{{ end }} {{- end }} ], + "wordCount" : "{{ .WordCount }}", + "inLanguage": {{ .Language.Lang | default "en-us" }}, {{ if .Params.cover.image -}} "image": {{- if (ne .Params.cover.relative true) -}} @@ -48,7 +52,7 @@ }, "publisher": { "@type": "{{- ( .Site.Params.schema.publisherType | default "Organization") | humanize -}}", - "name": {{ .Site.Params.title }}, + "name": {{ .Site.Title }}, "logo": { "@type": "ImageObject", "url": {{ .Site.Params.assets.favicon | default "favicon.ico" | absURL }}