Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timezone is set to UTC #60

Open
andys8 opened this issue Nov 19, 2018 · 2 comments
Open

Timezone is set to UTC #60

andys8 opened this issue Nov 19, 2018 · 2 comments

Comments

@andys8
Copy link
Contributor

andys8 commented Nov 19, 2018

Issue

The time zone is not read from the browser, but instead set to utc (edit: in the initializing phase).

, timeZone = Time.utc

, timeZone = Time.utc

, timeZone = Time.utc

See

https://package.elm-lang.org/packages/elm/time/latest/Time#here
https://guide.elm-lang.org/effects/time.html

@andys8 andys8 changed the title Timezone is hardcoded to "utc" Timezone is set permanently to UTC Nov 19, 2018
@catz
Copy link

catz commented Mar 13, 2019

Hello @andys8,

I guess it's totally ok because we run Task.perform GotTimeZone Time.here in init function and setup correct timezone then.

@andys8
Copy link
Contributor Author

andys8 commented Mar 13, 2019

I wouldn't go with "totally okay". If it is implemented in this way, then it's not that bad in practice, but there is one point in time where the state is not right.

"Making impossible states impossible" 😉
I know the checks are cumbersome, but we should go with Maybe a here.

Edit: I updated the initial issue text

@andys8 andys8 changed the title Timezone is set permanently to UTC Timezone is set to UTC Mar 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants