template/funcs.go
func parseJSON(s string) (interface{}, error) {
	if s == "" {
		return map[string]interface{}{}, nil
	}

	var data interface{}
	if err := json.Unmarshal([]byte(s), &data); err != nil {
		return nil, err
	}
	return data, nil
}
func parseJSON(s string) (interface{}, error) {
	if s == "" {
		return map[string]interface{}{}, nil
	}

	var data interface{}
	if err := json.Unmarshal([]byte(s), &data); err != nil {
		return nil, err
	}
	return data, nil
}
func parseJSON ( s string ) ( interface { } , error ) { if s == " " { return map [ string ] interface { } { } , nil } var data interface { } if err := json . Unmarshal ( [ ] byte ( s ) , & data ) ; err != nil { return nil , err } return data , nil }
// parseJSON returns a structure for valid JSON
parseJSON returns a structure for valid JSON