Closed kekbur closed 7 years ago
Seems like ember-moment is doing the right thing and moment-timezone introduced a breaking change in a patch release.
This workaround kept me going today:
https://github.com/moment/moment-timezone/issues/466
I can't really think of a way to keep the includeTimeZone options in sync with moment-timezone unless moment-timezone also followed and provided a 'truncated' option; which sounds like a more robust solution.
Maybe 'recent' over 'truncated'
I released ember-cli-moment-shim 3.0.3 to lock moment-timezone to <= 0.5.11 and I'm in the process of versioning 3.1.0 which will support 2012-2022 and will warn, but continue, if you have 2010-2020 set.
If you use 2010-2020 you'll see a deprecation warning to change the config option from "2010-2020" to "subset". This signifies you only want the "modern" subset of data and avoid another future bug in a few years when they rename the file again and change its content.
If your app targets 2010-2020, I'd lock the dependency of moment-timezone to <= 0.5.11. If your app is flexible enough to accept 2012-2022 (and whatever it becomes in the future) then don't worry about it.
3.1.0 was just versioned with the deprecation of "2010-2020" and the new option name "subset" (will scale better :)).
Can someone better explain how these subsets work? It saves some bytes to use the subset, instead of all, but I am unclear on when they change and if it might break things.
The latest release of moment-timezone (0.5.12) has broken the ember-moment configuration option
includeTimeZone: '2010-2020'
. The new truncated time zone data file covers years 2012-2022.Trying to use
2012-2022
as the configuration value produces the following output:Would it be possible to support configuration value
truncated
, which would automatically select the current truncated time zone dataset?