4 ms·
For json unmarshalling of structs at least, I've become a pretty big fan of the validator library from the go playground: github.com/go-playground/validator/v1
by SEJeff 7y ago
For json unmarshalling of structs at least, I've become a pretty big fan of the validator library from the go playground:
github.com/go-playground/validator/v10
It uses struct tags to validate the struct and is quite extensive.
https://godoc.org/gopkg.in/go-playground/validator.v10 https://godoc.org/gopkg.in/go-playground/validator.v10