isZIP
The isZIP function validates whether a given value is a valid ZIP code.
Works in: HTML5, React JS, Node.js
| Parameter | Type | Default | Description |
|---|---|---|---|
zipCode | string | number | undefined | The value to validate as a ZIP code. |
Usage
Example: Validate ZIP Code
const zipCode = '12345';
const isValidZIP = nfsfu234FormValidation.isZIP(zipCode);
console.log(isValidZIP); // trueSee also
Last updated on