User:Socktage/global.js

importScriptPage("User:Monchoman45/ChatHacks.js", "c"); if (mw.config.get("wgCanonicalSpecialPageName") == "Chat") { console.log("foo"); }