dark mode by default
See original GitHub issueDescription
How can i keep dark mode by default
Link to Reproduction
Steps to reproduce
- Go here when the website loads, the first white background appears then dark.
Chakra UI Version
latest
Browser
chrome
Operating System
- macOS
- Windows
- Linux
Additional Information
My theme config
import { extendTheme } from "@chakra-ui/react"
const config = {
initialColorMode: "dark",
useSystemColorMode: false,
}
const theme = extendTheme({ config })
export default theme
So, you can see that the dark mode is enabled by default, but it’s not appearing.
Users can only enable dark mode after clicking on the dark mode button.
Issue Analytics
- State:
- Created 2 years ago
- Comments:10 (3 by maintainers)
Top Results From Across the Web
Browse in Dark mode or Dark theme - Google Chrome Help
System Default if you want to use Chrome in Dark theme when Battery Saver mode is turned on or your mobile device is...
Read more >Default Dark Mode - Resource Packs - Minecraft - CurseForge
Default Dark Mode. The Dark Mode Resource Pack for Minecraft: Java Edition. This Resource Pack is a simple dark mode / dark theme...
Read more >Blackout: How to Enable Dark Mode on Your Browser | PCMag
On an Android device, tap the three-dot menu at the bottom of the browser and select Settings > Appearance and choose Dark or...
Read more >Why is dark mode not the default option? : r/UI_Design - Reddit
Dark mode is good for apps which are being used most frequently by users. For example, Reddit. It gives both the modes: dark...
Read more >95% of People Prefer Dark over Light Mode - Hacker News
I personally like dark mode during night time, but almost always prefer light mode by default. There's just something about dark mode that ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ats1999 one possible reason why this issue still exists for you is that at one point during development the chakra-ui set a flag in your local storage stating that the theme was
light
, you can maybe remove this flag and check if the website loads directly to the dark mode or not.It is set to Dark Mode, but you are experiencing an already known issue per the documentation
There are some solutions others have come up with. I cannot vouch for their effectiveness. Here’s one solution no-flash-chakra