• Hi,

    wouldn't it be nice to have a single global namespaced object for config vars needed in scripts configurable on a special page like a key value storage?

    For example, AjaxRC uses something like this to configurate the script before initialization:

    window.ajaxPages = ["Some Frequently Updated Page"];
    window.ajaxSpecialPages = ["Recentchanges", "WikiActivity", "Watchlist", "Log", "Contributions"];
    window.ajaxIndicator = '';
    window.ajaxRefresh = 30000;
    window.AjaxRCRefreshText = 'Auto-refresh';
    window.AjaxRCRefreshHoverText = 'Automatically refresh the page';

    This is ugly when occuring randomly in the Common.js (at worst multiple times at different places). Of course, the best way would be to store it on the server and load it simply server-site, but I was told by the support that they are not going to to this.

    The object could be stored in mw.custom or wgCustom or something with a completely new naming. The page could be namend Special:CustomConfigVars or something similar.

    What do you think about that? Thanks in advance for your feedback!


      Loading editor
    • I found out, that mediawiki suggests to use mw.libs.

        Loading editor
    • A FANDOM user
        Loading editor
Give Kudos to this message
You've given this message Kudos!
See who gave Kudos to this message
Community content is available under CC-BY-SA unless otherwise noted.