typescriptvalidations
v1.0.1
Published
this project contains validations functions
Downloads
6
Maintainers
Readme
##Typescript validations This project contains validations functions.
- validateString :
This function will check whether string is empty or not. If string is not empty , it returns true otherwise false.
validateEmail : This function will validate email. It returns true if email is valid otherwise false.
validateDate :
This function will validate date(yyyy/mm/dd) which may be leap year or normal year. It returns true if date is valid otherwise false.
- validateMobileNumber:
This function validates 10 digit mobile number, American mobile number with country code. It returns true if mobileNumber is valid otherwise false.
- validateCreditCardNumber
This function validates creditCardNumber such as American Express credit card, Visa credit card, Discover Card, Diners Club Card,JCB Card. It returns true if creditCardNumber is valid otherwise false.
##How to use :
first of all download this project by just running the below command "npm install typescript-validations"
Attach typescriptvalidations file in main html file . Ex :