Closed shackra closed 3 years ago
Yes, I agree. If you want to experiment with this, it is handled here https://github.com/tkrajina/typescriptify-golang-structs/blob/master/typescriptify/typescriptify.go#L87 it handles normal anonymous structs, but your one is is a pointer to a struct.
Fixed in dev
.
In Go I have the following struct
When you marshal that struct into JSON, the fields on
*jwt.Payload
get marshalled too if they have any data at all, however, typescriptify ignores it due to lack of the JSON tag, if you add the tag, the fields are included as part of another type, like so:I believe we should imitate how the fields end after a marshalling and output this result instead: