-
Notifications
You must be signed in to change notification settings - Fork 18.7k
Closed
Labels
Milestone
Description
Proposal:
It would be great if we could assign template tags to a struct so we can hide them from public view or rewrite the name when executing a template.
On many occasions we have to create a Public method. Having a tag similar to json on the struct would make so much sense.
I'm not sure if this has been discussed before but an example is below:
Example
File struct {
URL string `json:"url" template:"URL"`
Name string `json:"name" template: "-"`
}Thank you.
melekhine, obalunenko and ksthielemdlayher, jimen0, butuzov, kaey, mzattahri and 2 more