Skip to content

fix: current time widget shows build time instead of visitor's time - #714

Open
archiik04 wants to merge 1 commit into
containers:mainfrom
archiik04:fix/datetimebox-build-time
Open

fix: current time widget shows build time instead of visitor's time#714
archiik04 wants to merge 1 commit into
containers:mainfrom
archiik04:fix/datetimebox-build-time

Conversation

@archiik04

Copy link
Copy Markdown

Fixes #712

The "Current Time" box on the community page showed the time the site was built, not the visitor's actual time, because new Date() ran once on the build server. This PR wraps the clock formatting in a stateful Clock component and renders it client-side with <BrowserOnly>, updating the time in real-time.

Before screenshot

Live Production Site (time stays frozen at 06:40):

First check:
Screenshot 2026-08-18 101105

Several minutes later (still shows 06:40):
Screenshot 2026-08-18 101207

After screenshot

Local Site (time updates dynamically):

Initial load (shows 06:40):
Screenshot 2026-08-18 101147

One minute later (advances to 06:41):
Screenshot 2026-08-18 101157

Checklist

Ensure you have completed the following checklist for your pull request to be reviewed:

  • Certify you wrote the patch or otherwise have the right to pass it on as an open-source patch by signing all commits. (git commit -s).
  • PR description, commit message, and GitHub comments are human-written, per LLM Policy

Signed-off-by: Archi Kanungo <archi.kanungo2004@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: current time widget on community doesn't update, only refreshes on page reload

1 participant