tzdb icon indicating copy to clipboard operation
tzdb copied to clipboard

How to know when apply Daylight Time Savings?

Open fsc7 opened this issue 6 years ago • 2 comments

Hello, I have one question. How can I know when to apply the Daylight time savings?

fsc7 avatar Sep 17 '20 08:09 fsc7

@fsc7 To know that, you should use luxon: https://moment.github.io/luxon/docs/manual/tour.html which will automatically apply DST and also let you know if DST is active when creating a date for a zone at a specific time

tzdb does not contains the exact dates of when to apply DST changes. But luxon will use what your system knows (Node.js includes IANA database, which contains when DST changes).

Let me know if this works for you.

vvo avatar Sep 17 '20 22:09 vvo

@vvo thanks for the prompt response. I will give it a try.

fsc7 avatar Sep 18 '20 08:09 fsc7