MediaWiki:Common.js

/* Any JavaScript here will be loaded for all users on every page load. */ const darkModeButton = document.querySelector("#pt-darkmode-toggle > a");

darkModeButton.onClick = function { console.log(darkModeButton.value); }