This is for the next generation of MCS/PCS (Page Content Service) page content.
The goal of this is to reduce the payload for references by replacing the children of the <ol> tags that wrap references with a placeholder element (`<div>`?).In order to deliver just the content for the page - we should remove any content that can deferred until after first paint.
Additionally, To look for the reference <ol> tags we can use ol[typeof='mw:Extension/references']most of the information being extracted will be expected to be rendered by the client using native code or js.
Clients then can later request the reference list information of the same revision through another endpoint (e.g. `/page/references/:title/:rev`) and merge the content into each placeholder.
The placeholder element needsWe shoud leave a placeholder in for any content removed from the page so we can identify where it came from:
# a class to signify that it is a placeholder for references, so that clients could add onclick handlers if desired (`class=mw-references-placeholder`) and
# an identifier of the references listextracted content so that clients can find the right place in the DOM to replace the placeholder with the original `<ol>` tag (to get it in the original state). A client may also chose to add a new onclick handler on the `<ol>` tag for collapsing/opening the references list if desired.where it came from in the DOM
= BackgroundThis is currently being worked out here:
https://docs.google.com/spreadsheets/d/1RoP3gzbd-DbthjTbfim5z-c-qgjKXJOQE5rgZH3k4d0/edit#gid=0
Currently we have the following for sure:
- References
* Web did experiments in this area - https://www.mediawiki.org/wiki/Reading/Web/Projects/Performance/Lazy_loading_references- Page issues
- Hatnotes
- Categories
As part of this task we should figure out if we can deliver all of this information in a single API call or if we need to break it out into several APIs.