Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
sivar-utils
Advanced tools
Readme
TS/JS utils para el desarrollo de sistemas salvadoreños (Validacion de docs DUI, NIT, etc...)
npm install --save sivar-utils
import { isDUI } from 'sivar-utils';
const str = 'test';
const fakeDUI = '00000000-0';
const validDUI = '02495046-3'; // DISCLAIMER: taken from Google
isDUI(str); // false
isDUI(fakeDUI); // false
isDUI(validDUI); // true
import { isNIT } from 'sivar-utils';
const str = 'test';
const fakeNIT = '0000-000000-000-0';
const validNIT = '0614-051286-129-4'; // DISCLAIMER: taken from Google
const alsoValidNIT = '06140512861294';
isNIT(str); // false
isNIT(fakeNIT); // false
isNIT(validNIT); // true
isNIT(alsoValidNIT); // true
import { isMobilePhoneNumber } from 'sivar-utils';
const str = 'test';
const fakeMobilePhone = '9999-9999';
const validMobilePhone = '7071-1244'; // DISCLAIMER: taken from Google
isMobilePhoneNumber(str); // false
isMobilePhoneNumber(fakeMobilePhone); // false
isMobilePhoneNumber(validMobilePhone); // true
import { isResidentialPhoneNumber } from 'sivar-utils';
const str = 'test';
const fakeResidentialPhone = '5555-5555';
const validResidentialPhone = '2244-4777'; // DISCLAIMER: taken from Google
isResidentialPhoneNumber(str); // false
isResidentialPhoneNumber(fakeResidentialPhone); // false
isResidentialPhoneNumber(validResidentialPhone); // true
import { isPhoneNumber } from 'sivar-utils';
const str = 'test';
const fakePhone = '1234-5678';
const validPhone = '2591-3000'; /* or '7725-4747' */ // DISCLAIMER: taken from Google
isPhoneNumber(str); // false
isPhoneNumber(fakePhone); // false
isPhoneNumber(validPhone); // true
import { isPassport } from 'sivar-utils';
const str = 'test';
const fakePassport = '$03766021';
const validPassport = 'A12345678';
isPassport(str); // false
isPassport(fakePassport); // false
isPassport(validPassport); // true
import { isCarPlate } from 'sivar-utils';
const str = 'test';
const fakePlate = 'XY525929';
const validNationalPlate = 'N10731'; // DISCLAIMER: taken from Google
const validParticularPlate = 'p525929'; // DISCLAIMER: taken from Google
isCarPlate(str); // false
isCarPlate(fakePlate); // false
isCarPlate(validNationalPlate); // true
isCarPlate(validParticularPlate); // true
This is a commitizen friendly
repository, so instead of creating commits using git commit
, please use our custom CLI by running:
npm run cz
Make sure you have installed the following plugins on your Code Editor
Thanks goes to these wonderful people (emoji key):
Alejandro Paz ⚠️ 💻 | Jorge Monge 💻 🐛 | Ricardo Ramírez 🤔 | Jaime Leonardo Suncin Cruz 💻 ⚠️ 🤔 |
This project follows the all-contributors specification. Contributions of any kind welcome!
MIT © jonathanpalma
FAQs
Utilidades para validar documentos salvadorenos
The npm package sivar-utils receives a total of 21 weekly downloads. As such, sivar-utils popularity was classified as not popular.
We found that sivar-utils demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.