lesca-validate
v0.0.4
Published
check email, phone number, url format.
Downloads
3
Readme
Why use it?
check is validate email, phone number and url format.
Live Demo
Installation
npm install lesca-validate --save
Usage
As a Node module:
import {
ValidateEmail,
ValidatePhone,
ValidateURL,
ValidateYoutubeURL,
ValiDateInvoice,
} from 'lesca-validate';
const email = '[email protected]';
ValidateEmail(email); // true
const phone = '0912345678';
ValidatePhone(phone); // true
const url = 'https://google.com';
ValidatePhone(url); // true
const youtubeURL = 'https://www.youtube.com/watch?v=09839DpTctU';
ValidateYoutubeURL(youtubeURL); // '09839DpTctU';
const invoiceNumber = 'XS12345678';
ValiDateInvoice(invoiceNumber); // 'true';
Features
- maintain if necessary