Currently VisualEditor depends on RESTBase for performance, correctness (avoiding dirty diffs) and certain features (wikitext<->VE edit switching). After Parsoid was migrated to MediaWiki core, having RESTBase as a caching/stashing layer for VisualEditor no longer makes sense.
The goal of this task and it's subtasks it to support all RESTBase features needed by VisualEditor in MediaWiki core or VE extension.
VisualEditor depends on the following GET endpoints in RESTBase
- /page/html/{title} get latest parsoid HTML for a page.
- /page/html/{title}/{revision} - get parsoid HTML for a specific revision.
We already have corresponding endpoints in MediaWiki core, but some features are missing. Missing features:
- Language variant support T317019
- Stash for edit T267990
- Ability to either follow or suppress on-wiki redirects T301372
Additionally, VisualEditor depends on the following transform endpoints:
- /transform/html/to/wikitext {/title}{/revision} - accepts modified HTML and transforms it to wikitext. Only works if the data-parsoid was previously stashed.
- /transform/wikitext/to/html {/title}{/revision} - accepts modified wikitext and transforms it to HTML.
These endpoints don't need to be moved to restbase one-to-one, we might want to redesign how these work in process.