diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-04-02 16:02:13 +0300 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-04-02 16:07:01 +0300 |
commit | c5a5250a1b2897c8726cbf0d3be28d2db936bb4d (patch) | |
tree | 85486e40b78e2257b7c7e9c1fd9a39b82a0eb874 /layouts | |
parent | 2de831f4b9f459ab54b0f20d34f2168d817560e2 (diff) |
Use the new go-html-template Chroma lexer
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/shortcodes/code.html | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/layouts/shortcodes/code.html b/layouts/shortcodes/code.html index 83220c47d..2ee20b1eb 100644 --- a/layouts/shortcodes/code.html +++ b/layouts/shortcodes/code.html @@ -5,6 +5,9 @@ {{ $.Scratch.Set "codeLang" (index . 0 | strings.TrimPrefix ".") }} {{ end }} {{ with .Get "codeLang" }}{{ $.Scratch.Set "codeLang" . }}{{ end }} +{{ if eq (.Scratch.Get "codeLang") "html"}} +{{ $.Scratch.Set "codeLang" "go-html-template" }} +{{ end }} <div class="code relative" id="{{ $file | urlize}}"> {{- with $file -}} <div class="filename san-serif f6 dib lh-solid pl2 pv2">{{.}}</div> |