hello everyone 🙂 noob here
how come when i do a date it shows my locale timezone from local build (with npm run preview)
but when i deploy it to cloudflare the webpage i get is on UTC time.
i'd like it to be my timezone too
function timeElements(date: string, time: string) {
const timeFromString = new Date(`${date}T${time}:00.000+08:00`);
const formattedDateString = datefns.format(timeFromString, "MMM do, yyyy | K:mm XX") // added XX here to show timezone
const dateAttrVal = datefns.format(timeFromString, "yyyy-LL-dd KK:mm")
return (
<>
<time dateTime={dateAttrVal}>{formattedDateString}</time>
</>
)
}
in the images i've attached, the one that has +0800 in the end is my timezone and what i'd want it to look like but it has Z at the end from the deployed one
is there something i could specify in the webpage to force this?