I'm trying to use Moment
to format dates in this way YYYY-MM-DD HH:mm:ss
and would like to determine a time period between 00:00:00 p.m. yesterday and 23:59:59 today. Example: Considering today as 07/25/2017, it would look like:
dateFrom: 2017-07-24 00:00:00
dateTo: 2017-07-25 23:59:59
How do I generate those dates with Moment and force the formatting into YYYY-MM-DD HH:mm:ss
?