Giter Site home page Giter Site logo

Comments (1)

gilmoreorless avatar gilmoreorless commented on June 16, 2024 1

This is a similar issue to #1005, and I'll tweak my comment from there.

The data comes from the IANA time zone database (tzdb). There have been some changes with recent releases of tzdb, where time zones that have the same data since 1970 have been merged together, even if they're in different countries. This has definitely caused some confusion here and in other software projects.

The important thing is that identifiers like Europe/Prague are labels for regions of the world where the clocks agree. The country data you've quoted is not saying that Prague is in Slovakia. It's saying that the time in Slovakia can be represented by a time zone that happens to have the label Europe/Prague.

This can be seen in the tzdb source zone1970.tab:

CZ,SK +5005+01426 Europe/Prague

That line says that Czechia and Slovakia can both be represented by the same time zone rules. This would be equally true if the labels didn't have city names at all, but instead were named something like Europe/Zone073.

Note that Europe/Bratislava doesn't appear in that zone1970.tab file, because it's just a backwards-compatibility link to Europe/Prague. Moment Timezone adds the compatibility links to the country lists as well, based on the older (and deprecated) zone.tab.

I know this is a confusing situation. I'm going to leave this issue open as a reminder to write some proper documentation about it on the momentjs.com site.

from moment-timezone.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.