emmygozi-url-id-validator
v1.0.1
Published
This package validates a url id. It checks if id passed is a number and a positive integer.
Downloads
2
Maintainers
Readme
emmygozi-url-id-validator
This package validates a url id. It checks if id passed is a number and a positive integer
To Use: const idValidator = require('emmygozi-url-id-validator');
const idToBeTested = 'xxxx';
const idName = 'User';
console.log(idValidator(idToBeTested, idName));
"User ID is not valid!"