Skip to content

fix: add options to prevent ssr mismatch on settings#622

Closed
damevin wants to merge 3 commits intonpmx-dev:mainfrom
damevin:fix/date-setting-mismatch
Closed

fix: add options to prevent ssr mismatch on settings#622
damevin wants to merge 3 commits intonpmx-dev:mainfrom
damevin:fix/date-setting-mismatch

Conversation

@damevin
Copy link
Copy Markdown
Contributor

@damevin damevin commented Feb 1, 2026

What this PR do and why ?

Fixes a settings persistence issue where toggles could reset when opening a package page in a new tab or reloading. We now initialize settings after mount without overwriting existing localStorage, and add an E2E test to ensure settings persist across tabs and reloads.

How to setup and validate locally

  • Go to /settings, toggle any setting
  • Open /nuxt in a new tab
  • Reload /settings and /nuxt -> toggles stay as set
  • Optional: pnpm test:browser -- tests/settings.spec.ts

Related to #536

@vercel
Copy link
Copy Markdown

vercel Bot commented Feb 1, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
npmx.dev Ready Ready Preview, Comment Feb 1, 2026 9:45am
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Feb 1, 2026 9:45am
npmx-lunaria Ignored Ignored Feb 1, 2026 9:45am

Request Review

@danielroe
Copy link
Copy Markdown
Member

I can't actually reproduce this on npmx.dev

@damevin
Copy link
Copy Markdown
Contributor Author

damevin commented Feb 1, 2026

I think the bug was fixed by this #560 since we now have server/client component I've tested yesterday night lol, but it's looks good now

@damevin damevin closed this Feb 1, 2026
@danielroe
Copy link
Copy Markdown
Member

moving too fast! ⚡

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.

2 participants