DEV Community

Discussion on: 🌓 How to change the favicon according to system dark mode!

Collapse
 
smallsaucepan profile image
James Beard • Edited

Nice tutorial Max. Another option to capture mode changes between page loads would be to add an event listener to the media query. Explained here in this other example: jross.me/updating-your-website-fav...

Collapse
 
maxprogramming profile image
Max Programming

Thanks forr the suggestion James! I too think using the event listener is better than setInterval