uci-hugo-doc/layouts/shortcodes/include.html

8 lines
293 B
HTML
Raw Normal View History

2020-04-30 06:37:27 -07:00
{{$file := .Get "file"}}
{{- if eq (.Get "markdown") "true" -}}
{{- $file | readFile | markdownify -}}
{{- else if (.Get "language") -}}
{{- highlight ($file | readFile) (.Get "language") (default "linenos=table" (.Get "options")) -}}
{{- else -}}
{{ $file | readFile | safeHTML }}
{{- end -}}