I am currently utilizing the momentJS library for timezone conversion logic within my JavaScript code. I retrieve the User Preference Timezone abbreviation from a web service response, but when attempting to convert the date using the Timezone abbreviation, it does not seem to work correctly with certain timezones.
var formattedDate = moment(dateObject).tz("CST").format(getDateFormat.defaultDateFormat());
Is there a reliable method to convert a date based on a Timezone abbreviation using JavaScript?
Note: The functionality needs to successfully handle daylight saving time (DST) as well.
Your assistance in resolving this issue would be greatly appreciated.