Manual:Hooks/ResourceLoaderSiteModulePages

ResourceLoaderSiteModulePages
Available from version 1.35.0 (Gerrit change 547643)
Allows to change which wiki pages comprise the 'site' module in given skin.
Define function:
public static function onResourceLoaderSiteModulePages( string $skin, array &$pages ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"ResourceLoaderSiteModulePages": "MediaWiki\\Extension\\MyExtension\\Hooks::onResourceLoaderSiteModulePages"
	}
}
Called from: File(s): resourceloader/ResourceLoaderSiteModule.php
Function(s): getPages
Interface: ResourceLoaderSiteModulePagesHook.php

For more information about attaching hooks, see Manual:Hooks .
For examples of extensions using this hook, see Category:ResourceLoaderSiteModulePages extensions.


Parameters

edit
  • $skin: A string representing the current skin key
  • &$pages: A modifiable array representing a map of pages to their type