{{- $docsSection := .Site.GetPage "/docs" -}} {{- range $docsSection.Sections.ByParam "weight" -}} {{- if not (in .RelPermalink "/print") -}} {{- range .Pages.ByParam "weight" -}} {{- end -}} {{- end -}} {{- end -}}