-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add :allow-blank, validate-all #10
add :allow-blank, validate-all #10
Conversation
2435c7a
to
3e8f504
Compare
My problem with this is that I think I prefer not having the |
Remember you can have that I mention this because sometimes we forget we can do things from the outside. |
I plan to expose this api to end-users (developers). They define a list of validators for their form fields. So for me it's going to be required to have a simpler syntax than
for such a common need. I prefer them to write (list :allow-blank (len)) I want field declarations to be as simple as in Django. Also, it is quite logical to validate many validators, isn't it? (and "validator-collection" isn't simple?) My app already had to add the
yes, quite the contrary, often a lisper cooks his own food, it's too simple to not contribute!! ;) I'll think through the needs more.
I have to check… :allow-blank kind of does a early exit, I don't think the |
Ok. But I see that as part of your project. I prefer Clavier to only give you the building blocks in a consistent way.
Yes. But my point is "validate many validators" is equivalent to an
It does not. My point was about "validate many validators" being equivalent to an |
Ok. I see your point of |
Understood, and so be it. I wanted to extract that feature from my app, but I'm not happy with a fork or a trivial library. Let's see… |
WDYT?
It's shorter than "||" and "&&". It seems to be working OK.
for #7