Date
Compares operand
to test
(a Date
) and
returns a function that takes an optional arg
and uses it as the
operand or injects a argument from some other source (e.g., HTML element, query
string, session storage).
When called, the returned function returns the operand if it is
before/after/etc. the test date, otherwise returns an
Error
.
TODO: DateTime
can be a
String
, a PlainDate
, a
PlainDateTime
, or a ZonedDateTime
.
- IsAfterDate
= (datatype = "Date") => operand => test => (arg => Either<Error, Date)
- IsBeforeDate
= (datatype = "Date") => operand => test => (arg => Either<Error, Date)
- IsNotAfterDate
= (datatype = "Date") => operand => test => (arg => Either<Error, Date)
- IsNotBeforeDate
= (datatype = "Date") => operand => test => (arg => Either<Error, Date)