Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/complaindate/utils/localTimezone.ts>localTimezone

JavaScript date-time utilities that keep timezones on the surface
Latest
function localTimezone
import { localTimezone } from "https://deno.land/x/complaindate@v1.0.1/utils/localTimezone.ts";

Get the name of the system timezone, and fallback to "UTC" if the system doesn't expose a named timezone.

This is useful for setting the initial value of an HTML input where the user enters their timezone, or in a UI where the user has no option of selecting a preferred timezone.

Returns

string