Our users should be able to configure a time-in-day, and a timezone, by which they want to get daily updates. The updates should contain data that will be presented in their timezone of choice. For that, we probably want to store time & timezone data, per user.
I understand timetz
is discourage since it doesn’t take daylight savings into account. I also understand it’s necessary to store timezone string (like EST
) and not offset (like UTC+10
.
I can use time
for the time part, and text
for the timezone string, but it means I will have to sanitize the timezone data in code, which I’m trying to avoid.
What’s the best practice here?