typeschema
typeschema copied to clipboard
Fixed Class Validator using development debug messages
I just started using this implementation of class library and noticed I was getting really horrible error messages.
Turns out it's because this line https://github.com/decs/typeschema/blob/main/packages/class-validator/src/validation.ts#L26 was using a developer helper method https://github.com/typestack/class-validator/issues/26
I've added some tests to use the constrain messages. I've also flat mapped the errors so the messages are not combined (which I hope is ok but need more testing downstream in superforms).