Easy to use functional validators in Javascript
1–6 of 6 posts
Re: Easy to use functional validators in Javascript
#2Re: Easy to use functional validators in Javascript
#3Interesting: here the key point is composability. I wrote a validation library in the same vein but using functions as representations of sets https://github.com/gcanti/tcomb-validation
Re: Easy to use functional validators in Javascript
#4Embarrassingly, very few Node validation libraries support async!
This makes it annoyingly complex to have multiple sets of validation on the server to ensure a new user is indeed a new user, that foreign keys match their constraints, etc. on top of the dumb type checks.
We ultimately found Schemator from the js-data project: > http://www.js-data.io/v1.5.8/docs/js-data-schema
We've been able to put all of our sync/async constraints into varying "schemas" that run on both the client and the server!
Re: Easy to use functional validators in Javascript
#5Re: Easy to use functional validators in Javascript
#6I recently (as near as a week ago) started working on a modern JavaScript implementation of the same idea but without the tight coupling to a particular framework.
Very strange coincidence. :)