MCPcopy Index your code
hub / github.com/OpenSignLabs/OpenSign / formatTimeInTimezone

Function formatTimeInTimezone

apps/OpenSignServer/Utils.js:640–646  ·  view source on GitHub ↗
(date, timezone)

Source from the content-addressed store, hash-verified

638
639// Format date and time for the selected timezone
640export const formatTimeInTimezone = (date, timezone) => {
641 const nyDate = timezone && toZonedTime(date, timezone);
642 const generatedDate = timezone
643 ? format(nyDate, 'EEE, dd MMM yyyy HH:mm:ss zzz', { timeZone: timezone })
644 : new Date(date).toUTCString();
645 return generatedDate;
646};
647
648// `getSecureUrl` is used to return local secure url if local files
649export const getSecureUrl = url => {

Callers 1

formatDateTimeFunction · 0.70

Calls 1

formatFunction · 0.85

Tested by

no test coverage detected