Is it possible for me to convert
"Thu Oct 27 2022 02:00:00 GMT-0600 (Mountain Daylight Time)"
to this?
"Thu Oct 27 2022 02:00:00 GMT-0400 (New_York or whatever its actually called)"
I am using a component called react-datepicker
My datePicker is returning a date like this, Im in Colorado.
"Thu Oct 27 2022 02:00:00 GMT-0600 (Mountain Daylight Time)"
When i convert this to UTC i get
"2022-10-27T08:00:00Z"
My component is ALWAYS going to return me a time in my local timezone, which is Denver. I would like to be able to select a time, have it return me the first date, then somehow convert that to the second date in New york time.
"Thu Oct 27 2022 02:00:00 GMT-0400 (New_York or whatever its actually called)"
This way when I convert to utc I can get the output below
"2022-10-27T06:00:00Z"
Can anyone help me with this?