template.go
func (t *Template) ExecuteFuncString(f TagFunc) string {
	bb := t.byteBufferPool.Get()
	if _, err := t.ExecuteFunc(bb, f); err != nil {
		panic(fmt.Sprintf("unexpected error: %s", err))
	}
	s := string(bb.Bytes())
	bb.Reset()
	t.byteBufferPool.Put(bb)
	return s
}
func (t *Template) ExecuteFuncString(f TagFunc) string {
	bb := t.byteBufferPool.Get()
	if _, err := t.ExecuteFunc(bb, f); err != nil {
		panic(fmt.Sprintf("unexpected error: %s", err))
	}
	s := string(bb.Bytes())
	bb.Reset()
	t.byteBufferPool.Put(bb)
	return s
}
func ( t * Template ) ExecuteFuncString ( f TagFunc ) string { bb := t . byteBufferPool . Get ( ) if _ , err := t . ExecuteFunc ( bb , f ) ; err != nil { panic ( fmt . Sprintf ( " " , err ) ) } s := string ( bb . Bytes ( ) ) bb . Reset ( ) t . byteBufferPool . Put ( bb ) return s }
// ExecuteFuncString calls f on each template tag (placeholder) occurrence
// and substitutes it with the data written to TagFunc's w.
//
// Returns the resulting string.
//
// This function is optimized for frozen templates.
// Use ExecuteFuncString for constantly changing templates.
ExecuteFuncString calls f on each template tag ( placeholder ) occurrence and substitutes it with the data written to TagFunc s w . Returns the resulting string . This function is optimized for frozen templates . Use ExecuteFuncString for constantly changing templates .