Skip to content

Instantly share code, notes, and snippets.

View GonzaCoding's full-sized avatar
Coding...

GonzaCoding

Coding...
View GitHub Profile
@neiker
neiker / cuil-validator.ts
Last active April 16, 2024 22:08
Validación de CUIL (Argentina) en TypeScript / JavaScript
export function cuilValidator(cuil: string): boolean {
if (cuil.length !== 11) {
return false;
}
const [checkDigit, ...rest] = cuil
.split('')
.map(Number)
.reverse();