Skip to content

Conversation

@franciscolourenco
Copy link

validate('[email protected]', {presence: true, email: true});

closes #21

validate('[email protected]', {presence: true, email: true});

closes #21
@ansman
Copy link
Contributor

ansman commented Jul 28, 2014

I don't like the concept of having multi purpose functions.
It makes testing harder and there might be issues with assuming that all non objects should be validated like you propose.

I'd rather have a separate function such as validate.short or validate.single that does this.

@franciscolourenco
Copy link
Author

The purpose would be the same, just adding flexibility to the form of input it supports.
Instead of checking non objects it could check for boolean, number and strings.
But I understand your point.

@ansman
Copy link
Contributor

ansman commented Oct 5, 2014

Do you mind moving this to https://github.com/ansman/validate.js

All further development will be done there.

@franciscolourenco
Copy link
Author

Do you want the PR?

@ansman
Copy link
Contributor

ansman commented Oct 5, 2014

Yes please, thanks

@ansman ansman closed this Oct 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Abreviated notation for single field validation

2 participants