hugo-theme-introduction/exampleSite/layouts/shortcodes/readfile.html
Victoria Drake e781be1620 Add example site configuration post, shortcodes
- Hopefully help explain related issues #217, #194

Close #226
2020-07-25 09:57:40 -04:00

8 lines
No EOL
260 B
HTML

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