9 lines
221 B
TypeScript
9 lines
221 B
TypeScript
export const isToday = (date: Date) => {
|
|
const today = new Date();
|
|
return (
|
|
today.getDate() === date.getDate() &&
|
|
today.getMonth() === date.getMonth() &&
|
|
today.getFullYear() === date.getFullYear()
|
|
);
|
|
};
|