These are chat archives for gin-gonic/gin

Jan 2019
Jan 13 11:06

Hi there I hava a question...
What is the best way to partially serialize a structure?
Apis always so complex And return shape a lot.
Am I make a lots of return struct?

type User struct {

for example, when i return only user Adress, I will make userAdress struct.
the other hands, when i return only user name, I will make userName struct.
Is there a more concise way? How can I design for dynamic returns?
(I will delete it if it does not fit the subject.)