Join the conversation

Sign in to join this conversation, and others like it, in the communities you care about.

Frontend Hub

Talk anything related Frontend development, HTML/CSS, client side Javascript, Bootstrap, etc

Frontend Hub / General

Color scheme based on system preferences (Light or Dark mode)!

Color scheme based on system preferences (Light or Dark mode)!

Frontend Hub/General · May 2, 2019 at 7:39pm

Color scheme based on system preferences (Light or Dark mode)!

Frontend Hub / General · May 2, 2019 at 7:39pm

We will soon be able to write CSS for dark mode without using JavaScript to toggle the style! No more extra JavaScript in order to use the dark mode version of the website! This is already available on Safari, but it's coming to Firefox 67 and the Chrome team is already working on it!

Documentation:

https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme

Draft:

https://www.chromestatus.com/feature/5109758977638400

Can I Use:

https://caniuse.com/#search=prefers-color-scheme


May 6, 2019 at 10:07am

hey @vladio great share. Someone recently mention that Firefox support it already.

Finally ... like i remember missing that feature 10y ago ...

    Edited
    like-fill
    1
    • reply
    • like

    May 20, 2019 at 6:03pm

    Finally, someone knows the beauty of Dark mode haha

      like-fill
      1
      • reply
      • like