dateExtension.ts 283 Bytes edit raw blame history 1 2 3 4 5 6 7 8 9 10 export class DateExtension { public static ValidateDateRange(dateStart: string, dateEnd: string) { if (dateEnd === null) return false; const today = new Date(Date.now()); return (new Date(dateStart) <= today && today <= new Date(dateEnd)) ? true : false; } }