You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
In the code-snipped below, a new dayjs object is initialized and set to Asia/Tel_Aviv. This timezone is different from my own one, which is Europe/Berlin.
The object is set to the 31st of October 2021. On that day, Israel (and the majority of the remaining world, which is observing DST) will change back from Daylight Savings Time to Standard Time.
2 am correctly appears twice. However, the UTC offset incorrectly does not change. Instead of printing 02:00+03:00 twice, it should print 02:00+03:00 once, followed by 02:00+02:00
let day = dayjs('2021-10-31').tz('Asia/Tel_Aviv').startOf('day');
console.log(day.format('HH:mmZ'));
day = day.add(1, 'hour');
console.log(day.format('HH:mmZ'));
day = day.add(1, 'hour');
console.log(day.format('HH:mmZ'));
day = day.add(1, 'hour');
console.log(day.format('HH:mmZ'));
day = day.add(1, 'hour');
console.log(day.format('HH:mmZ'));
Expected behavior
Actual
Expected
00:00+03:00
00:00+03:00
01:00+03:00
01:00+03:00
02:00+03:00
02:00+03:00
02:00+03:00
02:00+02:00
03:00+03:00
03:00+02:00
Information
Day.js v1.10.6
OS: macOS Big Sur (11.5.2)
Browser: Google Chrome 92.0.4515.159 (Official Build) (x86_64)
Time zone: Europe/Berlin (we are currently on UTC+02:00)
The text was updated successfully, but these errors were encountered:
Describe the bug
In the code-snipped below, a new dayjs object is initialized and set to
Asia/Tel_Aviv
. This timezone is different from my own one, which isEurope/Berlin
.The object is set to the 31st of October 2021. On that day, Israel (and the majority of the remaining world, which is observing DST) will change back from Daylight Savings Time to Standard Time.
2 am correctly appears twice. However, the UTC offset incorrectly does not change. Instead of printing
02:00+03:00
twice, it should print02:00+03:00
once, followed by02:00+02:00
Expected behavior
Information
The text was updated successfully, but these errors were encountered: