Displaying User's Timezone Name

TL;DR: get the timezone abbrev and IANA name client-side from App Connect.

I’m building a validated app for user’s that both travel across multiple timezones with the same device and also for users that control other users around the globe. I’m aware that the date&time app component automatically converts user input time in accordance to the user’s current browser settings, but I need to allow users to both be aware of their current timezone setting and to override their current timezone using another and have it persist to their profile.

As a start, is anyone aware of how to format the date returned at the App Connect level to display the timezone to the user? Converting a DB UTC time to display localTime is trivial, but I’m totally stuck as to how to expose the current timezone abbreviation as well. Also, if I could somehow pull the full timezone name, I could then present it to the user as a default and allow them to re-select any of the IANA timezones and recompute the appropriate time via .addMinutes(). But I need a starting point by knowing what timezone the user happens to be in, and not just the UTCoffset as their settings are going to persist long-term (through eventual DST drifts). I do actually need to know the full IANA name (or close to it geographically).

Is anyone aware of how to do this using the current Wappler date formatters? Very much appreciated!

Community Page
Last updated: