{"action":"created","issue":{"url":"https://api.github.com/repos/Hacker0x01/react-datepicker/issues/679","repository_url":"https://api.github.com/repos/Hacker0x01/react-datepicker","labels_url":"https://api.github.com/repos/Hacker0x01/react-datepicker/issues/679/labels{/name}","comments_url":"https://api.github.com/repos/Hacker0x01/react-datepicker/issues/679/comments","events_url":"https://api.github.com/repos/Hacker0x01/react-datepicker/issues/679/events","html_url":"https://github.com/Hacker0x01/react-datepicker/issues/679","id":197245096,"number":679,"title":"Internal representation of time in UTC is wrong","user":{"login":"alex-shamshurin","id":1595209,"avatar_url":"https://avatars.githubusercontent.com/u/1595209?v=3","gravatar_id":"","url":"https://api.github.com/users/alex-shamshurin","html_url":"https://github.com/alex-shamshurin","followers_url":"https://api.github.com/users/alex-shamshurin/followers","following_url":"https://api.github.com/users/alex-shamshurin/following{/other_user}","gists_url":"https://api.github.com/users/alex-shamshurin/gists{/gist_id}","starred_url":"https://api.github.com/users/alex-shamshurin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alex-shamshurin/subscriptions","organizations_url":"https://api.github.com/users/alex-shamshurin/orgs","repos_url":"https://api.github.com/users/alex-shamshurin/repos","events_url":"https://api.github.com/users/alex-shamshurin/events{/privacy}","received_events_url":"https://api.github.com/users/alex-shamshurin/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-12-22T19:02:50Z","updated_at":"2016-12-27T10:14:33Z","closed_at":null,"body":"When user pickups some date he intended to select exactly that date which has been choosen, it must be not calculated or transformed somehow.  But I think in datePicker the date is stored in UTC.\r\n\r\nWell, my issue is about `minDate` and `maxDate`. I live in GMT +3, so at 01.00 AM local time is already 'tommorow', whereas UTC time is still 'yesterday'. So it leads to incorrect `minDate` date. User can chose previous date which totally breaks down a business logic.  To workaround I have to add time offset to moment constructor."},"comment":{"url":"https://api.github.com/repos/Hacker0x01/react-datepicker/issues/comments/269305960","html_url":"https://github.com/Hacker0x01/react-datepicker/issues/679#issuecomment-269305960","issue_url":"https://api.github.com/repos/Hacker0x01/react-datepicker/issues/679","id":269305960,"user":{"login":"alex-shamshurin","id":1595209,"avatar_url":"https://avatars.githubusercontent.com/u/1595209?v=3","gravatar_id":"","url":"https://api.github.com/users/alex-shamshurin","html_url":"https://github.com/alex-shamshurin","followers_url":"https://api.github.com/users/alex-shamshurin/followers","following_url":"https://api.github.com/users/alex-shamshurin/following{/other_user}","gists_url":"https://api.github.com/users/alex-shamshurin/gists{/gist_id}","starred_url":"https://api.github.com/users/alex-shamshurin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alex-shamshurin/subscriptions","organizations_url":"https://api.github.com/users/alex-shamshurin/orgs","repos_url":"https://api.github.com/users/alex-shamshurin/repos","events_url":"https://api.github.com/users/alex-shamshurin/events{/privacy}","received_events_url":"https://api.github.com/users/alex-shamshurin/received_events","type":"User","site_admin":false},"created_at":"2016-12-27T10:14:33Z","updated_at":"2016-12-27T10:14:33Z","body":"I agree, in DB time values must be stored in UTC, it's doubtless. But in my case it's just a train ticket date which user selects from the form. User cannot choose \"yesterday\" date, it's a relative value. It must be taken from user's browser and it's local time. It applies to the user only, it doesn't matter what is the time of other users. I need simply \"today\" and all following dates. So the internal date representation in Datepicker must be in local time. If I need to extract UTC time to store it in DB, it's a programmer's responsibility to do it."}}
{"actor":{"display_login":"alex-shamshurin"}}