Nick Young
Nick Young
CCConvex Community
Created by Nick Young on 1/15/2025 in #support-community
Returns Validation Error
I added some return validators to my convex queries. I get typescript errors if I don't return all the fields, however there are no typescript errors if I return extra fields. From what I understand, this is not possible in typescript?? However, the problem is I get a runtime error "ReturnsValidationError: Object contains extra field..." What is the recommended approach here? Can I either turn off this client side validation error, as I don't really care if there are extra fields, so long as the expected fields are there. Or is there some sort of parse/validation built in to the convex/values library to ensure that the validation requiremenets are met at build time not runtime?
3 replies