Sounds like an anti-pattern, but I don't see another way. I have lots of fields which may contain space characters (i.e. e-mail field). I validate e-mail with Joi.string().email().min(5).max(50).required(), but I want the next e-mail be valid " some-email@gmail.com ", and just trim when send to the server
Sounds like an anti-pattern, but I don't see another way. I have lots of fields which may contain space characters (i.e. e-mail field). I validate e-mail with
Joi.string().email().min(5).max(50).required()
, but I want the next e-mail be valid" some-email@gmail.com "
, and just trim when send to the server