chriso/node-validator — Issue #49: Renaming function names for consistency
Author: johnnywengluu
Created: 2011-11-30 04:33:06+00:00
State: open

It would be consistent if the following methods were renamed to:

not() -> isNot()
notNull() -> isNotNull()
notEmpty() -> isNotEmpty()
notContains() -> doesNotContain()
reqex() -> isRegExp() // Follow Javascript convention
notRegex() -> isNotRegExp()
len() -> hasLength()
notIn() -> isNotIn()
max() -> isMax()
min() -> isMin()

In this way it reads like english just like all the other methods.

I was going to implement this myself and make a pull request but I didn't know how to run the tests. How are they run and what testing library is it? (Mocha is a good one)