I thought creating a tag list is done in a few minutes, but right now I’m trying to find out why some tags are missing.
My code is:
{{ $count := 0 }}
<ul>
{{- range $name, $taxonomy := .Site.Taxonomies.tag }}
<li>{{ $name }} ({{ .Count }})</li>
{{ $count = add $count 1 }}
{{ end }}
</ul>
Number of tags: {{ $count }}
The code is placed in a shortcode and should display a list of the tags used on the site.
Output of the script is
Number of tags: 666
but when I look at the “public/tag” directory, I see 672 folders. Doing some manual comparison, I found that eg. “public/tag/w.a.s.p.” is indeed created as folder (and accessible from the browser), links to 4 pages but is missing in the list created by the code shown above.