[00:23:19] https://mediawiki.org/wiki/Manual:$wgResourceModules see also section at bottom contains a link to itself [00:23:32] infinite recursion! [00:24:51] I'm trying to find documentation that elaborates further on the "messages" key for each module in "ResourceModules" and what the list of message-keys in the array are for [00:26:15] https://mediawiki.org/wiki/Manual:Hooks/ResourceLoaderRegisterModules#Usage seems to reference it briefly [00:26:23] "ResourceLoaderModule objects, which provide access to scripts, styles, and messages can be added to the ResourceLoader at this point." [00:26:55] I suppose that implies providing access to external message-keys from outside of the extension [00:28:48] hmm, no, cuz I can use external messages without them being listed in extension.json [00:30:15] also, all the pages in the see also section include a link back to themselves too, cuz it's a template {{:ResourceLoader/See also}} [00:30:45] but maybe the template could factor in to programmatically exclude the current page [00:32:27] actually, I don't know what the : prefix means yet (I saw it somewhere a month ago) [00:33:04] aha, ordinary page used as a template [00:35:23] https://mediawiki.org/wiki/ResourceLoader/Developing_with_ResourceLoader "For more about the keys of the module definition (such as scripts, styles, messages, etc) see ResourceModules." but, but, but, that page has the string "messages" more informationally conveyed than the page being redirected to! lol [00:46:11] hmmm "_merge_strategy" I wonder what that key is for [00:47:12] it's documented in some file in the docs/ directory that documents extension registration, but it's basically needed to have certain multi-dimensional arrays and stuff work properly, but it's not a "one size fits all" thing so multiple merge strategies exist [00:48:06] Only 5 extensions use merge strategy ApprovedRevs CentralAuth CollapsibleVector DeletePagesForGood Lockdown [00:48:43] re:RL and "messages" key -- the "messages" array allows you to list a bunch of message keys so that you can use them in JS code as intended (with mw.msg() or mw.message( ... ).parse() or whatever; the latter is more feature-rich but requires a dependency on some other RL module, but mw.msg( ... ) is always available without having to declare a dependency on anything) [00:50:07] Aha! That type of information should be in the documentation somewhere, or if it is, made easier to find [00:51:07] RL is not the most beginner-friendly system out there, granted... [00:51:41] actually, I think it's quite friendly! Slight learning curve, but I like it so far! [00:51:50] \o/ [00:52:19] "mediawiki.jqueryMsg" is the name of the module which enables mw.message( ... ) with the various output formats similar to PHP wfMessage( ... ) [00:53:11] the documentation, on the other hand, I think the code and the doc are not on good terms with each other [00:53:50] heh, no kidding [00:55:06] that reminds me back during Second Life days 15+ years ago, I was developing a really awesome LSL script/program/service to offer to all sorts of land owners, renters and whatnot, to automate repeat visitors and offering custom tailored services and whatnot, but I sucked at preparing the documentation for my code, lol [00:56:31] or documentation for the service to end users in the metaverse [00:58:00] I feel your pain...I maintain a few things as well and the documentation is just woefully outdated and fails to convey across the awesomeness of the things in question (and no doubt many people would find these extensions/skins useful if they knew about 'em, and having proper documentation could be of great use for that, eh) [03:02:26] hmm, interesting https://mediawiki.org/wiki/Manual:Extension.json/Schema#MessagePosterModule [04:03:26] I'm not sure if this is a php issue or mediawiki issue, but in getConfigFactory()->makeConfig( 'PhotoSwipe' ); ?> and extension.json snippet being https://dpaste.org/ADuC8 on line 4 I'm confused why "options" is being treated as an array variable type in PHP instead of an object [04:05:09] https://stackoverflow.com/a/53811767 "This normally occurs when you are using the true option in the json_decode function. Just try to remove the true in the json_decode function and you should get an object." Hmmm [04:07:43] $this->addConfigGlobal( "$prefix$key", $val, $info['name'] ); // in includes/registration/ExtensionProcessor.php [04:10:09] Oh yeah, it's stored as an array, and 'options' is an array, hmmm [04:10:22] I meant to stay stored in $GLOBALS [04:31:43] Aha! Found it! https://github.com/wikimedia/mediawiki/blob/master/includes/registration/ExtensionRegistry.php#L372 [09:01:21] Needs better documentation: https://mediawiki.org/wiki/Manual:Status.php [09:01:59] I'm learning by looking at extensions code instead [09:02:41] but I always cringe to myself everytime worrying that the extensions might not be up-to-date in terms of best practices [09:04:41] Mostly I just discovered Status::newFatal() being used in some extensions that have i18n message keys using $1 in the text, and I want to be able to do the same, but I don't think wfMessage is able to preserve the code whilst also safely converting other user input or whatnot [09:06:59] Also I see some i18n message keys use $0. Hmmm, I wonder what that does [09:07:43] No mention of $0 in https://mediawiki.org/wiki/Manual:Messages_API [09:10:12] hmmm, but "mw.message( 'foobar' ).parse() Parses the message text from wikitext to HTML. This supports everything from text mode, as well as most links, and whitelisted HTML." [09:10:18] so then maybe isn't whitelisted [09:11:44] oooh, actually..., I must have done something wrong [09:12:32] cuz i18n message-key with value "foo
  • 3
bar" shows up as "foo

  • 3

bar" [09:14:36] Ah yep! I did something wrong! parsing twice [11:05:31] ryzenda: hmm, never heard of $0, I don't think that's a thing. Normally it starts at $1 [11:43:03] Hi, I have 3 sites and installed Wikibase on all of them. Everything works fine but for some reason the list of pages not showing in the sidebar so can someone please tell if there is any bug? Thanks [11:51:39] Koko: what conf8ig did you use [11:52:48] Hello Nemo_bis, config on repo or client wiki? [11:56:02] I'm using basic configs listed on this link https://www.mediawiki.org/wiki/Wikibase/Installation [12:04:14] I can see the option add links under "in other languages" and when I add a link it's not showing in the client wiki's sidebar. [17:38:48] How do I report a correction in a page without having to create an account? [17:44:58] Guest085: depends on the wiki; some may allow you to edit pages while logged out (although please note this records your IP address in the publicly-visible page history) [21:16:38] bawolff: re: $0, It didn't do anything in my experimenting, and I didn't find any information about it, but I stumbled upon other DynamicPageList using it, e.g. https://github.com/wikimedia/mediawiki-extensions-DynamicPageList/blob/master/i18n/en.json [21:16:54] p.s. they left, so they won't see my message