quri / react-bootstrap-datetimepicker

[DEPRECATED] A react.js datetime picker for bootstrap
http://dev.quri.com/react-bootstrap-datetimepicker/
MIT License
365 stars 292 forks source link

Can we work with moment in UTC mode? #174

Open justinwyllie opened 8 years ago

justinwyllie commented 8 years ago

E.g. when creating the moment I want to do this:

moment.utc('datetime string', 'format string', true) not moment.('datetime string', 'format string', true)

As per the moment docs:

By default, moment parses and displays in local time.

If you want to parse or display a moment in UTC, you can use moment.utc() instead of moment().

This brings us to an interesting feature of Moment.js. UTC mode.

Could this be added as a prop - to use moment in UTC mode?

foodaka commented 8 years ago

did you find a workaround for this? i also need this

justinwyllie commented 8 years ago

basically no. the date was displayed to the users in local time. we converted it to UTC to send to our back-end.