File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
site/themes/arangodb-docs-theme/layouts/partials Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change 1717{{- with $versionShort }}
1818< meta name ="docsearch:version " content ="{{ . }} ">
1919{{- end }}
20- {{- if eq .Path "/arangodb/" }}
20+ {{- if (hasPrefix .Path "/arangodb/") }}
21+ {{- if or (.Page.Store.Get "deprecated") (.Page.Store.Get "inDevelopment") }}< meta name ="robots " content ="noindex "> {{ end }}
22+ {{- if and (eq (.Page.Store.Get "alias") "stable") (not (hasPrefix .RelPermalink "/arangodb/stable/")) }}
23+ {{- $splitLink := split .RelPermalink "/" }}
24+ {{- $s := slice "/arangodb" "stable" }}
25+ {{- range $i, $e := $splitLink }}
26+ {{- if gt $i 2 }}{{ $s = $s | append $e }}{{ end }}
27+ {{- end }}
28+ < link rel ="canonical " href ="{{ delimit $s "/" }}">
29+ {{- end }}
2130 {{- $shortVersions := slice }}
2231 {{- $versions := index site.Data.versions "/arangodb/" }}
2332 {{- range $version := $versions }}
24- {{- $shortVersions = $shortVersions | append $version.name }}
33+ {{- $shortVersions = $shortVersions | append (cond (eq $version.name $version.alias) $version.name $version.alias) }}
2534 {{- end }}
2635 < meta name ="docsearch:version " content ="{{ delimit $shortVersions ", " }}">
2736{{- end }}
You can’t perform that action at this time.
0 commit comments