hugo-theme-relearn/layouts/partials/_relearn/dependencies.gotmpl

8 lines
377 B
Go Template
Raw Normal View History

2024-09-07 22:11:36 +00:00
{{- range .Site.Params.relearn.dependencies }}
{{- $has := printf "has%s" .name }}
{{- $disable := printf "disable%s" .name }}
{{- $wants := or (and (ne (index $.Params $disable) nil) (not (index $.Params $disable))) (and (ne (index $.Site.Params $disable) nil) (not (index $.Site.Params $disable))) }}
{{- if $wants }}
{{- $.Store.Set $has true }}
{{- end }}
{{- end }}