DEV Community

Discussion on: Light and dark mode in just 14 lines of CSS

Collapse
 
waylonwalker profile image
Waylon Walker

I've been wanting to implement this for awhile, If I want to also include an override toggle button, do I need js?

Collapse
 
shammisharma profile image
shammisharma

yes I think js will be a proper way to implement it. Although we can use : checked , :not(: checked) property of checkbox. but I'm not sure how it will turn out.