timezone-boundary-builder
js-joda
Our great sponsors
timezone-boundary-builder | js-joda | |
---|---|---|
7 | 7 | |
818 | 1,586 | |
- | 0.9% | |
8.0 | 7.5 | |
about 1 month ago | 9 days ago | |
JavaScript | JavaScript | |
MIT License | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
timezone-boundary-builder
-
Falsehoods programmers believe about time zones
They don't really bother me. They aren't AI spam, and some folks may enjoy them. It's pretty easy to not click on a link, for me.
TZ are a fun project. I found that it's difficult to translate a long/lat into a TZ ID, so I wrote this[0].
Works a charm. It's based on the Timezone Boundary Builder[1].
[0] https://github.com/LittleGreenViper/LGV_TZ_Lookup
[1] https://github.com/evansiroky/timezone-boundary-builder
-
SpatiaLite: Library extending SQLite to support Spatial SQL capabilities
I wrote a tutorial on SpatiaLite here: https://datasette.io/tutorials/spatialite - "Building a location to time zone API with SpatiaLite"
It shows how to use SpatiaLite + Datasette to build an API that can tell you what timezone a latitude/longitude point is in, using data derived from OpenStreetMap via https://github.com/evansiroky/timezone-boundary-builder
Here's a demo: https://timezones.datasette.io/timezones/by_point?longitude=... - add ".json" to the URL for the JSON output.
- Does a country's legislated time zones extend to the limit of its territorial sea or its exclusive economic zone?
-
Falsehoods programmers believe about time
I have never had an opportunity to deploy this tool, but here's a program for generating a TZ shapefile from OpenStreetMap data:
https://github.com/evansiroky/timezone-boundary-builder
In principle a calendar program could use its output to perform GIS lookups of locations then use the tzinfo DB to get the correct timezone at the given location and specified time.
-
How can I get a user's timezone based on location and create a DateTime() based on that timezone?
You could ask google. Amazon or Microsoft probably offer similar APIs. Or you can do it yourself. It's a very complicated topic, though.
-
Big problems at the timezone database
There is a separate timezone boundary builder which maps geography to timezones using a shapefile, and the shapefile is >35MB uncompressed. By comparison the latest tzdata is 1.2M uncompressed.
- how do i konw the datum for a country? in postgis?
js-joda
-
Everything you need to know about Date in Programming
js-joda
-
Making your datepicker easier to work with
So first, a simple example of how this works. Using our "What is your birthday" example, we can mock up this code. Note: I'm using TypeScript because it enforces the concepts at compile time, but the JsJoda library itself enforces the concepts at runtime so that we get the best of both.
-
[HELP] Time elapsed since midnight breaks on days when DST changes
Dealing with human dates is non-trivial thanks to localization. The easiest thing to do is to start with something zone agnostic (like UTC or epoch) do your date calculation, and then shift that into the locale you want. date-fns is fine for basic date math, but if you want something more robust, with a more cohesive API, I'd recommend js-joda.
-
You don't (may not) need Moment.js
How come the js-joda library is never mentioned in discussions about javascript date/time libraries? its API is perfect and it has been around forever. but instead the community seems to keep inventing more and more new datetime libraries. i don't understand why js-joda seems to be ignored
https://js-joda.github.io/js-joda/
- Temporal: Getting started with JavaScript's new date time API
-
Updates from the 81st meeting of TC39
I've been getting by with js joda. Temporal is a welcome addition.
-
How to format dates without Moment.js
Support for the domain models LocalDate, LocalDateTime, ZonedDateTime, Instant, Duration and Period. Also, supports IANA timezone, adding the plugin @js-joda/timezone you'll have access to the IANA timezone database with all the timezones available.
What are some alternatives?
geolocator - A utility for getting geo-location information via HTML5 and IP look-ups, geocoding, address look-ups, distance and durations, timezone information and more...
Luxon - ⏱ A library for working with dates and times in JS
OpenRailwayMap - An OpenStreetMap-based project for creating a map of the world's railway infrastructure.
date-fns - ⏳ Modern JavaScript date utility library ⌛️
openinframap - Open Infrastructure Map
dayjs - ⏰ Day.js 2kB immutable date-time library alternative to Moment.js with the same modern API
awesome-falsehood - 😱 Falsehoods Programmers Believe in
moment - Parse, validate, manipulate, and display dates in javascript.
proposal-temporal - Provides standard objects and functions for working with dates and times.
You-Dont-Need-Momentjs - List of functions which you can use to replace moment.js + ESLint Plugin
ngx-moment - moment.js pipes for Angular
proposal-temporal-v2 - Future additions to Temporal