You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I’ve added my blog website to the Google search console and found out BreadcrumbList JSON-LD Schema.org 2 is not working well. I have the following issue for every blog post and tag pages. Last ListItem is missing elements: name, type etc.
ListItem 1 contains type, id, url, and name elements but Listitem 2 (it's always the last listitem) only contains id and missing the name element, which is not considered a rich element by Google.
I've checked the structured-data.html and found out {{ if ne (add $index 1) $len -}} this condition is skipped so else condition is used for articles.
"itemListElement": [{{ $list := $.Scratch.Get "breadcrumb" }}{{ $len := (len $list) }}{{ range $index, $element := $list }}{{ if ne .position 1 }},{{ end }}{
"@type": "ListItem",
"position": {{ .position }},
"item": {
{{ if ne (add $index 1) $len -}}
"@type": "WebPage",
"@id": {{ .url }},
"url": {{ .url }},
"name": "{{ .name | humanize | title }}"
{{ else -}}
"@id": {{ .url }}
{{ end -}}
}
}{{ end }}]
Is there a solution to fix this? I’m not sure about the underlying issue here. I have checked other Hinode websites, and they don’t have this problem.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
I’ve added my blog website to the Google search console and found out BreadcrumbList JSON-LD Schema.org 2 is not working well. I have the following issue for every blog post and tag pages. Last ListItem is missing elements: name, type etc.
ListItem 1 contains type, id, url, and name elements but Listitem 2 (it's always the last listitem) only contains id and missing the name element, which is not considered a rich element by Google.
I've checked the structured-data.html and found out
{{ if ne (add $index 1) $len -}}
this condition is skipped so else condition is used for articles.Is there a solution to fix this? I’m not sure about the underlying issue here. I have checked other Hinode websites, and they don’t have this problem.
Beta Was this translation helpful? Give feedback.
All reactions