github.com/geraldss/go/src@v0.0.0-20210511222824-ac7d0ebfc235/html/template/attr_string.go (about) 1 // Code generated by "stringer -type attr"; DO NOT EDIT. 2 3 package template 4 5 import "strconv" 6 7 const _attr_name = "attrNoneattrScriptattrScriptTypeattrStyleattrURLattrSrcset" 8 9 var _attr_index = [...]uint8{0, 8, 18, 32, 41, 48, 58} 10 11 func (i attr) String() string { 12 if i >= attr(len(_attr_index)-1) { 13 return "attr(" + strconv.FormatInt(int64(i), 10) + ")" 14 } 15 return _attr_name[_attr_index[i]:_attr_index[i+1]] 16 }