How to Toggle Light/Dark Mode with CSS and JavaScript

Опубликовано: 29 Октябрь 2024
на канале: CODE WITH HOSSEIN
2,357
like

Hey guys 😀 In this tutorial, We're gonna learn How to Design a super fascinating Light/Dark Mode Toggle Switch with HTML, CSS & JavaScript. So if you wanna improve your JS skills and also learn how Light & Dark Modes work, you definitely have to watch this helpful video, You can also download the source code for free 👇

📂 Assets
Icons: https://boxicons.com/

🔗 Source code
https://github.com/hosseinnabi-ir/How...

🔔 Subscribe Now!
   / @codewithhossein  

⏱ Timestamps
00:00 Draggable Toggle in Desktop Version
00:20 Touchable Toggle in Mobile Version
00:47 Toggle Switch HTML Code
01:06 General Styles
01:27 Switch Styles
03:33 JavaScript Code for Mobile Version
06:10 JavaScript Code for Desktop Version
07:11 Turning off the excess scrollbars
07:53 Final Result

🎵 Music
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Track: BEAUZ & JVNA - Crazy [NCS Release]
Music provided by NoCopyrightSounds.
Watch:    • BEAUZ & JVNA - Crazy | Electronic Pop...  
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Track: Lost Sky - Vision pt. II (feat. She Is Jules)
Music provided by NoCopyrightSounds.
Watch:    • Lost Sky - Vision pt. II (feat. She I...  
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Track: Lost Sky - Where We Started (feat. Jex)
Music provided by NoCopyrightSounds.
Watch:    • Lost Sky - Where We Started (feat. Je...  
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Thanks for watching, I appreciate it 🙏
Made with 💗 by Hossein