Skip to content

Instantly share code, notes, and snippets.

View regpaq's full-sized avatar
🤙

Reggie Paquette regpaq

🤙
View GitHub Profile
@nickpunt
nickpunt / lightswitch.js
Last active September 12, 2019 13:39
Lightswitch: A dark mode switcher with user override
/*******************************************************************************
LIGHTSWITCH: A DARK MODE SWITCHER WITH USER OVERRIDE
By Nick Punt 10/26/2018
How to use:
* Create two color schemes in CSS under the classes 'light' and 'dark'
* Add the class 'light' or 'dark' to your body as your default color scheme
* Add button to page with id 'lightswitch', which lets users change/override