The Javascript standard library literally has no way to do math on non-local timezones, so if we want to get e.g. the "spam the thing at local midnight" scheduling correct we need a separate package. We already take a dependency on moment-timezone for the purposes of node-schedule so it's a natural choice here. It also greatly cleans up the "format this in local time" code.
The Javascript standard library literally has no way to do math on non-local timezones, so if we want to get e.g. the "spam the thing at local midnight" scheduling correct we need a separate package. We already take a dependency on
moment-timezone
for the purposes ofnode-schedule
so it's a natural choice here. It also greatly cleans up the "format this in local time" code.