Looking at the readfile shortcode:
{{$file := .Get "file"}}
{{- if eq (.Get "markdown") "true" -}}
{{- $file | readFile | markdownify -}}
{{- else -}}
{{ $file | readFile | safeHTML }}
{{- end -}}
I want to create a similar shortcode, but I’m not sure what language this is written in? I want to be able to concatenate .Get "file"
with a string to result in $file
. I’m not finding anything in the documentation outlining this.
Admittedly, it’s very confusing to know what can be used where within hugo. There’s YAML, TOML, HTML, MD, its own syntax, etc. Is this documented somewhere I’m not finding?