Skip to content

Persist Dark/Light Mode Across Page Reloads #336

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
shivasankaran18 opened this issue Mar 27, 2025 · 1 comment · May be fixed by #337
Open

Persist Dark/Light Mode Across Page Reloads #336

shivasankaran18 opened this issue Mar 27, 2025 · 1 comment · May be fixed by #337

Comments

@shivasankaran18
Copy link

Feature Request 🛍️

Persist Dark/Light Mode Across Page Reloads

Use Case

Currently, the website defaults to the light theme after a page reload, even if the user has previously selected the dark theme. This disrupts the user experience as the theme preference is not retained.

Possible Solution

Store the user's theme preference (dark or light) in localStorage and apply it during app initialization to ensure the selected theme persists across page reloads.

Context

This issue affects the overall user experience by not respecting the user's theme preference. Persisting the theme across page reloads will improve usability and make the website feel more polished.

Detailed Description

  • The selected theme (dark or light) should persist across page reloads.
  • The theme preference should be stored in localStorage and applied when the page loads.
  • The data-theme attribute should be updated correctly to ensure the styles are applied consistently.
  • The solution should be tested to verify that the theme persists and behaves as expected.
@shivasankaran18
Copy link
Author

shivasankaran18 commented Mar 27, 2025

@DianaLease @dselman @ekarademir I would like to work on this issue ..

@shivasankaran18 shivasankaran18 linked a pull request Mar 27, 2025 that will close this issue
5 tasks
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 a pull request may close this issue.

1 participant