4 ms·
>>> pass a map[string]string to json.Marshal() This is my goto speed hack when prototyping. It always works. You don't have to worry about deep nesting. And it
by ArtWomb 7y ago
>>> pass a map[string]string to json.Marshal()
This is my goto speed hack when prototyping. It always works. You don't have to worry about deep nesting. And it frees you to design the data model as you prototype. It's also less punishing than reflecting on every node in a list.
And yes, golang / json (and go / node) interactions need to evolve better developer patterns and runtime performance ;)