Created
April 22, 2020 00:06
-
-
Save jasonlutterloh/f0a3524dddc05ebc981f0d7224b8977c to your computer and use it in GitHub Desktop.
CSS Media Query for Dark Mode
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
body { | |
background: #fff; | |
color: #222; | |
} | |
@media (prefers-color-scheme: dark) { | |
body { | |
background: #222; | |
color: #efefef; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment