From 68cc8a115d79c97e3c557c70d81d59d0de29ae46 Mon Sep 17 00:00:00 2001 From: a73x Date: Sat, 31 Aug 2024 18:51:42 +0100 Subject: feat(html): add syntax highlighting using a js library until I work out how to use https://github.com/alecthomas/chroma --- public/static/highlight.go.js | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 public/static/highlight.go.js (limited to 'public/static/highlight.go.js') diff --git a/public/static/highlight.go.js b/public/static/highlight.go.js new file mode 100644 index 0000000..d851930 --- /dev/null +++ b/public/static/highlight.go.js @@ -0,0 +1,20 @@ +/*! `go` grammar compiled for Highlight.js 11.10.0 */ +(()=>{var e=(()=>{"use strict";return e=>{const a={ + keyword:["break","case","chan","const","continue","default","defer","else","fallthrough","for","func","go","goto","if","import","interface","map","package","range","return","select","struct","switch","type","var"], + type:["bool","byte","complex64","complex128","error","float32","float64","int8","int16","int32","int64","string","uint8","uint16","uint32","uint64","int","uint","uintptr","rune"], + literal:["true","false","iota","nil"], + built_in:["append","cap","close","complex","copy","imag","len","make","new","panic","print","println","real","recover","delete"] + };return{name:"Go",aliases:["golang"],keywords:a,illegal:"