hugo weird list

hugo weird list

SHRIK3 (i@shrik3.com (SHRIK3))

this is just a unused listing style. keeping it here because I spent quite some time on it. (Quite some hackary…)

The idea is that a post e.g. /content/post/foo/bar/that.md

should be renered into

&LTspan>::post::foo::bar::<&LTa href="link">>that&LT/a>&LT/span>

in this case pages should be sorted w/ their path (as in file path).

partial namespace-list-plain.html

&LTpre>
{{- range .}}
{{- $cat := split .Path "/" }}
{{- if gt (len $cat) 1 }}
{{- $cat := after 2 $cat }}
{{- end}}
{{- $cat = first (sub (len $cat) 1) $cat}}
{{- $prefix := delimit $cat "::"}}
{{$prefix}}::&LTa href="{{ .Permalink }}">{{ .Title }} &LT/a>
{{- end }}
&LT/pre>

Generated by RSStT. The copyright belongs to the original author.

Source

Report Page