validator
https://github.com/go-playground/validator
Go
:100:Go Struct and Field validation, including Cross Field, Cross Struct, Map, Slice and Array diving
Triage Issues!
When you volunteer to triage issues, you'll receive an email each day with a link to an open issue that needs help in this project. You'll also receive instructions on how to triage issues.
Triage Docs!
Receive a documented method or class from your favorite GitHub repos in your inbox every day. If you're really pro, receive undocumented methods or classes and supercharge your commit history.
Go not yet supported1 Subscribers
Add a CodeTriage badge to validator
Help out
- Issues
- Question about the use of ne
- How to check file extension (MIME Types) when upload file
- Want a string comparing validator which ignores cases
- support custom error message
- Question about single-dimension array with `required,dive,required`
- Comparison for int 0 not work
- `omitempty` on pointer non primitive field goes to nested custom rule on "" (empty string) but successfully ignores validation on nested structure field when pointer is nil
- Custom validator not called for multipart.FileHeader type
- question: validate field if some other field == some value?
- Interface conversion error is nil not validator.validationerrors for valid request body.
- Docs
- Go not yet supported