anotherValue := "aValue"
Banana := map[string]map[string]interface{}{
"amap": map[string]interface{}{
"aKey": "aValue",
"anotherKey": fmt.Printf("another Value %s", anotherValue)
},
}
I am trying to do a string interpolation with a variable inside a map, for a “value”. Refer value of “anotherKey” from above. If you see I am trying to do fmt.Printf() but that doesnt work. How can I solve this problem of string interpolation/formatting for a “key/value” inside a map?
I tried few different options but nothing seem to work.