Checks for a valid date string.
Matches m/d/yy, m-d-yy, mm/dd/yyyy and mm/dd/yyyy, allowing any combination of one or two digits for the day and month, and two or four digits for the year.
isDateString('11/11/2011'); // true isDateString('1/5'); // false isDateString(true); // false
The value to check.
Whether the value is a date string.
Generated using TypeDoc
Checks for a valid date string.
Matches m/d/yy, m-d-yy, mm/dd/yyyy and mm/dd/yyyy, allowing any combination of one or two digits for the day and month, and two or four digits for the year.
isDateString('11/11/2011'); // true isDateString('1/5'); // false isDateString(true); // false