- Returns all keys from the (private) registry object as an array
- Needed for ResourceLoader 2 in order to do autosuggestions for dependancies and cheap non-http-request lookups to avoid duplicate keys when creating new modules/gadgets.
(bug 30160 ) Add public method to mw.loader to get module names from registry
* (bug 30022) Add support for custom loadScript sources to ResourceLoader.
* (bug 19052) Unicode space separator characters (Zs) now terminates external
links and images links.
+* (bug 30160) Add public method to mw.loader to get module names from registry.
=== Bug fixes in 1.19 ===
* $wgUploadNavigationUrl should be used for file redlinks if
return null;
};
+ /**
+ * Get names of all registered modules.
+ *
+ * @return {Array}
+ */
+ this.getModuleNames = function() {
+ var names = $.map( registry, function( i, key ) {
+ return key;
+ } );
+ return names;
+ };
+
/* Cache document ready status */
$(document).ready( function() { ready = true; } );