- [Date Validators](#module_Date Validators)
- [.isDateValidator](#module_Date Validators.isDateValidator) ⇒
boolean
- [.isDateNotUnder18Validator](#module_Date Validators.isDateNotUnder18Validator) ⇒
boolean
- [.isBirthDateValidator](#module_Date Validators.isBirthDateValidator) ⇒
boolean
- [.isAfterTodayValidator](#module_Date Validators.isAfterTodayValidator) ⇒
boolean
- [.isBeforeTodayValidator](#module_Date Validators.isBeforeTodayValidator) ⇒
boolean
- [.isExpiryDateValidator](#module_Date Validators.isExpiryDateValidator) ⇒
boolean
- [.isReleaseDateValidator](#module_Date Validators.isReleaseDateValidator) ⇒
boolean
- [.isDateValidator](#module_Date Validators.isDateValidator) ⇒
Checks if value is valid date in format YYYY-MM-DD. Validates also number of days per month
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if person with given birthday is above 18 years. Date in format YYYY-MM-DD
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
date | string |
value to check. |
Checks if value is valid birth date. Assumes that human cannot be older than 150 years. Date in format YYYY-MM-DD
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
date | string |
value to check. |
Checks if given date is after today. Date in format YYYY-MM-DD
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
date | string |
value to check. |
Checks if given date is before today. Date in format YYYY-MM-DD
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
date | string |
value to check. |
Checks if given expiration date of id card is valid. Checks if given date is later or equal to today and if given date is smaller than current date plus 100 years. Date in format YYYY-MM-DD
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
date | string |
value to check. |
Checks if given release date of id card is valid. Checks if given date is earlier or equal to today and if given date is bigger than current date minus 100 years. You can also pass expiration date and if it's given then it is checked if expiration date is later than release date. Date in format YYYY-MM-DD
Kind: static property of [Date Validators
](#module_Date Validators)
Param | Type | Description |
---|---|---|
date | string |
value to check. |
expiryDate | string |
acc. |
- [General Validators](#module_General Validators)
- [.isValueValidator](#module_General Validators.isValueValidator) ⇒
boolean
- [.isNotNullValidator](#module_General Validators.isNotNullValidator) ⇒
boolean
- [.isNotUndefinedValidator](#module_General Validators.isNotUndefinedValidator) ⇒
boolean
- [.isNotEmptyUnlessValidator](#module_General Validators.isNotEmptyUnlessValidator) ⇒
boolean
- [.isNotEmptyStringValidator](#module_General Validators.isNotEmptyStringValidator) ⇒
boolean
- [.isNotEmptyTrimmedStringValidator](#module_General Validators.isNotEmptyTrimmedStringValidator) ⇒
boolean
- [.isSelectedValidator](#module_General Validators.isSelectedValidator) ⇒
boolean
- [.isNipValidator](#module_General Validators.isNipValidator) ⇒
boolean
- [.isPostalCodeValidator](#module_General Validators.isPostalCodeValidator) ⇒
boolean
- [.isPasswordValidator](#module_General Validators.isPasswordValidator) ⇒
boolean
- [.isNotSmallerValidator](#module_General Validators.isNotSmallerValidator) ⇒
boolean
- [.isNotSmallerOrEqualValidator](#module_General Validators.isNotSmallerOrEqualValidator) ⇒
boolean
- [.isNotHigherValidator](#module_General Validators.isNotHigherValidator) ⇒
boolean
- [.isNotHigherOrEqualValidator](#module_General Validators.isNotHigherOrEqualValidator) ⇒
boolean
- [.isEmailValidator](#module_General Validators.isEmailValidator) ⇒
boolean
- [.isMinLengthValidator](#module_General Validators.isMinLengthValidator) ⇒
boolean
- [.isMaxLengthValidator](#module_General Validators.isMaxLengthValidator) ⇒
boolean
- [.isSameAsValidator](#module_General Validators.isSameAsValidator) ⇒
boolean
- [.isOtherThanValidator](#module_General Validators.isOtherThanValidator) ⇒
boolean
- [.isIbanValidator](#module_General Validators.isIbanValidator) ⇒
boolean
- [.isIbanLengthValidator](#module_General Validators.isIbanLengthValidator) ⇒
boolean
- [.isLanNumberValidator](#module_General Validators.isLanNumberValidator) ⇒
boolean
- [.isRoutingCodeValidator](#module_General Validators.isRoutingCodeValidator) ⇒
boolean
- [.isTaxNumberValidator](#module_General Validators.isTaxNumberValidator) ⇒
boolean
- [.isSwiftValidator](#module_General Validators.isSwiftValidator) ⇒
boolean
- [.isSwiftCountryValidator](#module_General Validators.isSwiftCountryValidator) ⇒
boolean
- [.isIdNumberValidator](#module_General Validators.isIdNumberValidator) ⇒
boolean
- [.isPassportValidator](#module_General Validators.isPassportValidator) ⇒
boolean
- [.isPropValidator](#module_General Validators.isPropValidator) ⇒
boolean
- [.isAllKeysValidator](#module_General Validators.isAllKeysValidator) ⇒
boolean
- [.isLatinValidator](#module_General Validators.isLatinValidator) ⇒
boolean
- [.isValueValidator](#module_General Validators.isValueValidator) ⇒
Checks if any proper value was given
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | any |
value to check. |
Checks if value is not null
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | any |
value to check. |
Checks if value is not undefined
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | any |
value to check. |
Checks if value was given unless can be empty.
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
canBeEmpty | boolean |
if true validation is ignored |
Checks if value is not empty string
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | any |
value to check. |
Checks if value is not empty string after trim
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if any option was chosen. Created for select2 library
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string | boolean |
value to check. |
Checks if value is valid nip number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value is valid polish or chinese postal code
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
country | string |
country of postal code. |
Checks if value is valid password with 8 signs
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value is smaller than given minimal value
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
minValue | string |
minimal value. |
Checks if value is smaller or equal than given minimal value
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
minValue | string |
minimal value. |
Checks if value is higher than given maximal value
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
maxValue | string |
maximal value. |
Checks if value is higher or equal than given maximal value
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
maxValue | string |
maximal value. |
Checks if value is valid email. Based on w3.org
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value has smaller or equal length than given minimal length
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
minLength | string |
minimal length. |
Checks if value has bigger or equal length than given maximal length
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
maxLength | string |
maximal length. |
Checks if value is equal to other value
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
otherValue | string |
other value to check. |
Checks if value is not equal to other value
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
otherValue | string |
other value to check. |
Checks if value is valid iban number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
countryCode | CountryCode |
country code. |
Checks if value is valid iban number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
countryCode | CountryCode |
country code. |
Checks if value is valid non-iban account number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
[country] | string |
optional country to check. |
Checks if value is valid routing code
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
[country] | string |
optional country to check. |
Checks if value is valid tax number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
[country] | string |
optional country to check. |
[isCompany] | boolean |
optional isCompany to check. |
Checks if value is valid swift number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if given country is equal to country taken from swift
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
swift | string |
swift to check. |
country | string |
country to compare. |
Checks if value is valid polish id number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value is valid polish passport number
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if given object has property valid and if it is equal to true
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | Object |
value to check. |
Checks if given object has all keys
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
object | object |
value to check. |
expectedKeys | Array.<string> |
array of expected keys. |
Checks if value is in Latin alphabet or matches any kind of punctuation character or matches any math symbols, currency signs, dingbats, box-drawing characters, etc
Kind: static property of [General Validators
](#module_General Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
- Patterns
- .isAccountNumberPattern ⇒
boolean
- .isAccountTypeOtherPattern ⇒
boolean
- .isAlphaNumericPattern ⇒
boolean
- .isCityPattern ⇒
boolean
- .isGenericTextPattern ⇒
boolean
- .isLastNamePattern ⇒
boolean
- .isNamePattern ⇒
boolean
- .isNipPattern ⇒
boolean
- .isNumericPattern ⇒
boolean
- .isPasswordPattern ⇒
boolean
- .isBankAccountNamePattern ⇒
boolean
- .isCharsCompanyPattern ⇒
boolean
- .isPostalCodePattern ⇒
boolean
- .isStreetPattern ⇒
boolean
- .isPolishStreetPattern ⇒
boolean
- .isAccountNumberPattern ⇒
Checks if value matches account number pattern
/^[a-zA-Z0-9\\s]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches account type pattern
/^[a-zA-ZąćęłńóśźżĄĆĘŁŃÓŚŹŻ. ]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches alpha numeric pattern
/^[a-zA-Z0-9]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches city pattern
/^([a-zA-Z\u0080-\u024F]+(?:. |-| |'))*[a-zA-Z\u0080-\u024F]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches generic text pattern
/^[0-9a-zA-ZąćęłńóśźżĄĆĘŁŃÓŚŹŻ\s\,\.\-\+\(\)\!\?\:Kind: static property of
Patterns
\n]*$/:
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches last name pattern
/^[a-zA-Z\u00C0-\u017F\-\s\']*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches name pattern
/^[a-zA-ZąćęłńóśźżĄĆĘŁŃÓŚŹŻ ]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches nip pattern
/^[a-zA-Z0-9\s\-]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches numeric pattern
/^[0-9]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches password pattern
/^[0-9a-zA-ZąćęłńóśźżĄĆĘŁŃÓŚŹŻ\s\-\+\_\\!Kind: static property of
Patterns
#$%^&*|"';:,.?()[]{}]*$/:
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches bank account name pattern
/^[0-9a-zA-Z\u00C0-\u017F\xad\xa0\u201c\u201d\u201e\u201f\u2013\_\;\'Kind: static property of
Patterns
-\s",./-+&()]*$/:
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches company name pattern
/^[a-zA-Z0-9\u00C0-\u017F\xad\xa0\u201c\u201d\u201e\u201f\u2013\_\;Kind: static property of
Patterns
-\s.,&`':()!*"/\+]*$/:
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches postal code pattern
/^[a-zA-Z0-9 \-]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches street name pattern
/^[0-9a-zA-Z\u00C0-\u017F\-\s\.,\/]*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value matches pattern
/[a-zA-Z\\u00C0-\\u017F]+\\s\\d.*$/
Kind: static property of Patterns
Param | Type | Description |
---|---|---|
value | string |
value to check. |
- [Pesel Validators](#module_Pesel Validators)
- [.isPeselNotUnder18Validator](#module_Pesel Validators.isPeselNotUnder18Validator) ⇒
boolean
- [.isPeselValidator](#module_Pesel Validators.isPeselValidator) ⇒
boolean
- [.isPeselNotUnder18Validator](#module_Pesel Validators.isPeselNotUnder18Validator) ⇒
Checks if person with given pesel is above 18 years
Kind: static property of [Pesel Validators
](#module_Pesel Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
Checks if value is valid pesel number. Also accepts *********** as anonymized pesel
Kind: static property of [Pesel Validators
](#module_Pesel Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
- [Phone Number Validators](#module_Phone Number Validators)
- [.isPhoneValidator](#module_Phone Number Validators.isPhoneValidator) ⇒
boolean
- [.isMobilePhoneValidator](#module_Phone Number Validators.isMobilePhoneValidator) ⇒
boolean
- [.isPhoneValidator](#module_Phone Number Validators.isPhoneValidator) ⇒
Checks if value is valid phone number. Based on google libphonenumber
Kind: static property of [Phone Number Validators
](#module_Phone Number Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
countryCode | CountryCode |
country code. |
Checks if value is valid mobile phone number. Based on google libphonenumber
Kind: static property of [Phone Number Validators
](#module_Phone Number Validators)
Param | Type | Description |
---|---|---|
value | string |
value to check. |
countryCode | CountryCode |
country code. |