hugo/layouts/shortcodes/readfile.html

6 lines
163 B
HTML
Raw Normal View History

{{$file := .Get "file"}}
{{- if eq (.Get "markdown") "true" -}}
{{- $file | readFile | markdownify -}}
{{- else -}}
{{ $file | readFile | safeHTML }}
{{- end -}}