Add a dark-mode theme toggle with a Bootstrap Custom Switch
The Dark Mode Switch is a lightweight and customizable dark mode toggle switch that can be added to any website using Bootstrap. It allows users to switch between light and dark themes and utilizes local storage to store the user’s preference. With a minified and gzipped size of only 383 Bytes, it offers a quick and efficient way to enable dark mode on a website.
To install the Dark Mode Switch, you can follow these steps:
git clone https://github.com/coliff/dark-mode-switch.git
.npm install dark-mode-switch
.yarn add dark-mode-switch
.The Dark Mode Switch is a simple yet powerful tool for adding a dark mode toggle to any website. With its lightweight code and easy installation process, it provides a seamless way to enhance the user experience by providing a dark theme option. Utilizing local storage, it remembers the user’s preference, allowing for a consistent dark mode experience across visits.