@technobuddha/library
Version:
A large library of useful functions
16 lines (15 loc) • 458 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.isAlphaNumeric = void 0;
var reAlphaNumeric = /^(\p{L}|\p{N})+$/u;
/**
* Test a string for all alphanumeric characters
*
* @param input string to test
* @return true, if all characters in the string are alphanumeric
*/
function isAlphaNumeric(input) {
return reAlphaNumeric.test(input);
}
exports.isAlphaNumeric = isAlphaNumeric;
exports.default = isAlphaNumeric;