https://github.com/mlascurain/toggle-dark-mode
Web Component, using LocalStorage, ShadowDOM and Custom HTML Elements
https://github.com/mlascurain/toggle-dark-mode
custom-elements javascript localstorage shadow-dom web-components
Last synced: 5 months ago
JSON representation
Web Component, using LocalStorage, ShadowDOM and Custom HTML Elements
- Host: GitHub
- URL: https://github.com/mlascurain/toggle-dark-mode
- Owner: mLascurain
- Created: 2024-08-27T20:27:44.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-25T23:02:31.000Z (over 1 year ago)
- Last Synced: 2025-02-01T17:45:32.097Z (over 1 year ago)
- Topics: custom-elements, javascript, localstorage, shadow-dom, web-components
- Language: JavaScript
- Homepage:
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Toggle-Dark-Mode

Clone the repository or download the file and add the following lines into your html file

```
```
After that create your styles for dark mode and light mode in the dark-mode/light-mode classes
If you want to change the style of the button just comment all the styles in the js file.