DiegoLopesLima/warble

Accept function on the "is" param.

Closed this issue · 0 comments

Example:

warble.validate(value, {
	is: function(value) {

		return value !== null;

	}
});

// or

warble.validate(value, {
	is: ['numeric', function(value) {
	
		return value !== 0;

	}]
});