behavior:
- Built-in darkmode respects system theme preference.
- Manual theme toggles persist in browser
localStorage.
Note
For adding, removing, or configuring plugins, see the Configuration page.
Customization
options:
disable: - Delete darkmode from quartz.config.yaml. - Or set enabled: false.
install: - npx quartz plugin add github:quartz-community/darkmode
source: - quartz-community/darkmode
Event Listener
usage:
- Listen for
themechangeto run custom logic on theme toggle:
document.addEventListener("themechange", (e) => {
console.log("Theme changed to " + e.detail.theme) // "light" or "dark"
})