func interpolate(text []byte, name, value string) ([]byte, error) {
	text = escapePattern(text)

	re, err := compile(name)
	if err != nil {
		return nil, err
	}

	text = re.ReplaceAll(text, []byte(value))

	return unescapePattern(text), nil
}
// interpolate replaces instances of the name pattern with the value.
interpolate replaces instances of the name pattern with the value.
// interpolate replaces instances of the name pattern with the value .
func interpolate(text []byte, name, value string) ([]byte, error) {
	text = escapePattern(text)
	re, err := compile(name)
	if err != nil {
		return nil, err
	}
	text = re.ReplaceAll(text, []byte(value))
	return unescapePattern(text), nil
}
func interpolate ( text [ ] byte , name , value string ) ( [ ] byte , error ) { text = escapePattern ( text ) re , err := compile ( name ) if err != nil { return nil , err } text = re . ReplaceAll ( text , [ ] byte ( value ) ) return unescapePattern ( text ) , nil }
interpolate replaces instances of the name pattern with the value.
interpolate replaces instances of the name pattern with the value .