You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Run the following commands to start npm install --legacy-peer-deps and npm run dev
Current behavior
Dark mode not getting applied.
Expected behavior
On refreshing the page the dark mode should apply.
Context
When I switch the theme to Dark mode, it updates the Redux state and also preserved to LocalStorage. When I do a hard refresh in the browser, reading the theme preference from Redux and applying it. But the Dark theme is not showing.
@siriwatknp I have updated the code with InitColorSchemeScript and it's already using the cssVariables. Still the issue persists.
Also do you have any reference implementation project with Dark mode toggle?
Steps to reproduce
Steps:
npm install --legacy-peer-deps
andnpm run dev
Current behavior
Dark mode not getting applied.
Expected behavior
On refreshing the page the dark mode should apply.
Context
When I switch the theme to Dark mode, it updates the Redux state and also preserved to LocalStorage. When I do a hard refresh in the browser, reading the theme preference from Redux and applying it. But the Dark theme is not showing.
Screen.Recording.2025-01-06.at.1.53.20.PM.mov
Your environment
npx @mui/envinfo
Search keywords: nextjs dark mode
The text was updated successfully, but these errors were encountered: