import { formatDateToCompare } from './format' ; export function isAfter ( input , date ) { return formatDateToCompare ( input ) > formatDateToCompare ( date ) ; } export function isBefore ( input , date ) { return formatDateToCompare ( input ) < formatDateToCompare ( date ) ; } export function isBetween ( to , from , date ) { return isAfter ( date , to ) && isBefore ( date , from ) ; } export function isSame ( input , date ) { return formatDateToCompare ( input ) === formatDateToCompare ( date ) ; } export function isSameOrAfter ( input , date ) { return isSame ( input , date ) || isAfter ( input , date ) ; } export function isSameOrBefore ( input , date ) { return isSame ( input , date ) || isBefore ( input , date ) ; }