Split time zone calculations and formatting
- Dominant language
- JavaScript
- Stars
- 256
- Forks
- 26
- PR merge metrics
- No merged PRs in 30d
Description
Hey,
This is a good and convenient library for getting the time in another time zone. But what the heck is it doing formatting and returning strings? These are two entirely orthogonal use cases and should be in separate functions, if not separate libraries. We've already got n+1 string and date formatting libraries. We don't seem to have decent time zone libraries. At least I haven't found any.
Last I checked it was not possible to get an array of numeric time values out of the main function here? I've resorted to splitting a string of year, month etc. values. I hope you agree that it quite nuts to first turn numbers into strings based on a format string and then turn that little serialization format back into numbers. ^_^
Or am I missing something obvious and it's easy-peasy to get back the plain old date field numbers in a given time zone for any given UTC time? Thanks!
Contributor guide
No contributing guide indexed for this repository
Research direction
The issue names no files or tests; begin by locating the library's main function and checking how it currently formats time-zone results. Define the scope with maintainers before proceeding, since the requested separation of calculations and formatting is architectural; done would mean callers can obtain numeric date fields without parsing formatted strings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- tooling
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100