You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One of the reasons I use https://github.com/ghodss/yaml is because it supports the json struct tag -- so I don't have to have multiple definitions of the same fields:
// I DO NOT want thistypeFoostruct {
A`json:"foo" yaml:"foo"`B`json:"bar,omitempty", yaml:"bar,omitempty"`...
}
// I WANT this to work with this YAML librarytypeBarstruct {
A`json:"foo"`B`json:"bar"`
}
I would really like this library to (1) by default look at the YAML tag, and (2) if not found, look at the JSON tag
The text was updated successfully, but these errors were encountered:
One of the reasons I use
https://github.com/ghodss/yaml
is because it supports thejson
struct tag -- so I don't have to have multiple definitions of the same fields:I would really like this library to (1) by default look at the YAML tag, and (2) if not found, look at the JSON tag
The text was updated successfully, but these errors were encountered: