mirror of
https://github.com/rustdesk/doc.rustdesk.com.git
synced 2025-08-17 16:35:40 +00:00
33 lines
852 B
HTML
33 lines
852 B
HTML
{{/* Enhanced breadcrumb with Schema.org markup for better SEO */}}
|
|
{{ if not .Params.disableBreadcrumb }}
|
|
{{ $ancestors := slice }}
|
|
{{ $current := . }}
|
|
{{ range $current.Ancestors.Reverse }}
|
|
{{ $ancestors = $ancestors | append . }}
|
|
{{ end }}
|
|
|
|
{{ if $ancestors }}
|
|
<script type="application/ld+json">
|
|
{
|
|
"@context": "https://schema.org",
|
|
"@type": "BreadcrumbList",
|
|
"itemListElement": [
|
|
{{ range $index, $ancestor := $ancestors }}
|
|
{
|
|
"@type": "ListItem",
|
|
"position": {{ add $index 1 }},
|
|
"name": "{{ $ancestor.Title }}",
|
|
"item": "{{ $ancestor.Permalink }}"
|
|
}{{ if ne $index (sub (len $ancestors) 1) }},{{ end }}
|
|
{{ end }}
|
|
,{
|
|
"@type": "ListItem",
|
|
"position": {{ add (len $ancestors) 1 }},
|
|
"name": "{{ .Title }}",
|
|
"item": "{{ .Permalink }}"
|
|
}
|
|
]
|
|
}
|
|
</script>
|
|
{{ end }}
|
|
{{ end }} |