Welcome to mirror list, hosted at ThFree Co, Russian Federation.

list-keywords-range.html « utils « partials « layouts - github.com/2-REC/hugo-myportfolio-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 2ecd4d8f9ea6406aa528be35d7679ec636814c44 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
{{/*
    Parameters:
    - type: "tags" or "categories"
    - context: (project_sections)
    - site: (Site)
    - scratch: (Scratch)
    - removeDuplicates: BOOL
*/}}

{{ .scratch.Delete .type }}
{{ range .context }}
    {{ with $.site.GetPage "section" . }}
        {{ $params := (dict "type" $.type "context" . "scratch" $.scratch "removeDuplicates" $.removeDuplicates) }}
        {{ partial "utils/get-keywords.html" $params }}
    {{ end }}
{{ end }}
{{ .scratch.Set .type (uniq (.scratch.Get .type)) }}

{{ range (.scratch.Get .type) }}
    <a href="{{ (print "/" $.type "/") | relLangURL }}{{ . | urlize }}" title="{{ . }}">
        {{ . }}
    </a>
{{ end }}
{{ .scratch.Delete .type }}