validate-lib
TypeScript icon, indicating that this package has built-in type declarations

0.1.1 • Public • Published

Validate-lib

Validaciones utiles para formularios

  • RUN o Rut Chileno

Instalar libreria

npm i validate-lib

Importar la libreria

import { validateRut, deleteDots, deleteDash } from 'validate-lib';

Validar Rut

const rut = '98.336.313-k';
const isValid = validateRut(rut);

if(isValid){
  //Si
} else {
  //No
}

Limpiar rut

import { deleteDots, deleteDash } from 'validate-lib';
const rut = '98.336.313-k';
deleteDots(rut); // return 98336313-k
deleteDash(rut); // return 98.336.313k

/validate-lib/

    Package Sidebar

    Install

    npm i validate-lib

    Weekly Downloads

    1

    Version

    0.1.1

    License

    MIT

    Unpacked Size

    16.5 kB

    Total Files

    12

    Last publish

    Collaborators

    • fabianisaac