In addition you can implement prefers-color-scheme media queries to also trigger dark mode, if this is set in user preferences: developer.mozilla.org/en-US/docs/W...
prefers-color-scheme
@media (prefers-color-scheme: dark) { --bg: black; --font-color: white; --btn-bg: white; --btn-color: black; }
I also read somewhere that you can also hook into the ambient sensor of the laptop.
Not sure if the following was the original published source but that's where I read it. blog.arnellebalane.com/using-the-a...
That's awesome!
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
In addition you can implement
prefers-color-scheme
media queries to also trigger dark mode, if this is set in user preferences: developer.mozilla.org/en-US/docs/W...I also read somewhere that you can also hook into the ambient sensor of the laptop.
Not sure if the following was the original published source but that's where I read it.
blog.arnellebalane.com/using-the-a...
That's awesome!