Regex, React, JavaScript, Nodejs, Development.
isDateValid('2019-12-18'); // date is valid isDateValid('2019-2-18'); // date is invalid 4. Empty string validation: ^\s*$ Explanation: This regular expression checks to see if the string contains only spaces function isEmpty(value) { if(/^\s*$/.test(value)) { console.log('string is empty or