Closed larsnystrom closed 8 years ago
I can't figure out how to validate that a field should be a non-empty list of structs. Is that possible?
Aha, now I see. Sorry for the ticket, here's the solution if somebody else has this problem:
const tMyListOfThings = t.subtype(t.list(tMyThing), x => x.length > 0, 'MyListOfThings');
I can't figure out how to validate that a field should be a non-empty list of structs. Is that possible?