hugo-WonderMod/assets/js/theme.js
2022-07-23 04:15:25 +02:00

9 lines
289 B
JavaScript

// for now this is assuming default theme is set to dark
// will probably refactor in the future for much better handling
function loadPreferredTheme() {
if (localStorage.getItem("pref-theme") === "light") {
document.body.classList.remove('dark')
}
}
loadPreferredTheme();