michaelwittig / node-q

Q interfacing with Node.js
MIT License
52 stars 14 forks source link

timezone #25

Closed ritalg closed 7 years ago

ritalg commented 7 years ago

why a Date date type from q getting converted to datetime in json ? example 2016.09.20 to 2016-09-20T00:00:00.000Z

How to change the timezone form utc to eastern?

michaelwittig commented 7 years ago

Q: Date date type from q getting converted to datetime in json A: q has many more types than JavaScript. All temrporal types are converted to Date in JavaScript. See this table Date date type from q getting converted to datetime in json

Q: How to change the timezone form utc to eastern? A: q has no idea about timezones. Besides that, how can a date have a time zone? What are you trying to do? If you want to do more sophisticated temporal stuff in JavaScript I can recommend http://momentjs.com/