Manual:Hooks/ParserOutputStashForEdit

ParserOutputStashForEdit
Available from version 1.27.0 (Gerrit change 266644)
Called when an edit stash parse finishes, before the output is cached.
Define function:
public static function onParserOutputStashForEdit( WikiPage $page, Content $content, ParserOutput $output, string $summary, User $user ) { ... }
Attach hook:

In extension.json:

{
	"Hooks": {
		"ParserOutputStashForEdit": "MyExtensionHooks::onParserOutputStashForEdit"
	}
}
Called from:File(s): Storage/PageEditStash.php
Function(s): parseAndCache
Interface:ParserOutputStashForEditHook.php

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

DetailsEdit

  • $page: the WikiPage of the candidate edit
  • $content: the Content object of the candidate edit
  • $output: the ParserOutput result of the candidate edit
  • $summary: the change summary of the candidate edit
  • $user: the User considering the edit