commit | fce9be6e96eae7f56e124896f8bbdb6c1e5261e1 | [log] [tgz] |
---|---|---|
author | sbailey <[email protected]> | Tue Nov 07 16:45:12 2023 -0800 |
committer | sbailey <[email protected]> | Mon Nov 13 12:09:09 2023 -0800 |
tree | 8f84791a41a203e06f6076e9be45ebfe5ea5c8a8 | |
parent | 7998cfc59c611dc6d5d91f89267c6c1a9fc6cc87 [diff] |
Adding Tools link use core parser for this page link * If 'Enable parser migration tool' and/or 'Use Parsoid by default' has been enabled in the user preferences, a new link is add Tools sidebar to allow the use of the legacy parser or Parsoid to render the current page. Bug: T350599 Change-Id: I6773a9f63bb7c443708f0ec983bade9881b10400
The ParserMigration extension provides an interface for comparing article rendering with a new non-default version of the MediaWiki parser, thus serving as a parser migration tool.
It was deployed on the Wikimedia production cluster during 2018 to compare Tidy-based output with a RemexHTML-based replacement.
In 2023 it was overhauled to compare legacy parser output with Parsoid output.
Add:
wfLoadExtension( 'ParserMigration' );
to your LocalSettings.php
to enable.
Running npm test
and composer test
will run automated code checks.
This extension adds action=parser-migration
to the MediaWiki action API, which parses a page with two different parser configurations and returns one or both variants in the API response.
It also adds 'Enable parser migration tool' to the list of 'Developer tools' options at the bottom of the 'Editing' options for a user. When this is enabled, an "Edit with migration tool" link is added to the Tools menu in the sidebar for article pages. Clicking this on an article page will bring up a variant of the "preview edit" page which allows you to compare the legacy parser output against Parsoid output.