Checks if value is a Date object.
value
The value to check.
Returns true if value is a Date object, false otherwise.
true
false
const value1 = new Date();const value2 = '2024-01-01';console.log(isDate(value1)); // trueconsole.log(isDate(value2)); // false Copy
const value1 = new Date();const value2 = '2024-01-01';console.log(isDate(value1)); // trueconsole.log(isDate(value2)); // false
Alias