func RemoveBOM()

in pkg/preprocess/bom.go [17:25]


func RemoveBOM(b []byte) []byte {
	b = encodeToUTF8(b)
	for _, bs := range bomSequences {
		if bytes.HasPrefix(b, bs) {
			return b[len(bs):]
		}
	}
	return b
}