-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a timezonechange event to Window/WorkerGlobalScope
The current timezone is visible to JavaScript and changes over time. Changes may be useful to note, e.g., in a long-running calendar or mail application that may want to update dates and times without refreshing when the user resumes using the application after travel. Currently, to accomplish that, a webapp would have to poll, e.g., by repeatedly calling `Intl.DateTimeFormat().resolvedOptions().timeZone`. With this patch, an event would instead notify the application. In this patch, the time zone may change before the task is run, but must be changed at the point the task is run. A previous version included additional guarantees, that the time zone would not be changed until the start of the task, but these semantics add implementation complexity and no concrete use case was found for the greater guarantees.
- Loading branch information
Showing
1 changed file
with
41 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters