🌱 Darm Mode Toggle

Source

The issue is that most toggles are two states: you either have light mode or dark mode and the choice is forever stored in a cookie or localStorage. And that makes your dark mode toggle broken.

Just like prefers-color-scheme toggles between three states, your dark mode toggle should also toggle between three states:

  1. light
  2. dark
  3. system
Made by Brandon . If you find this project useful you can donate.