We currently update pages dynamically after changes are saved on desktop using the HTML from the save success response. However, we don't do this on mobile. Instead, the page is reloaded. [i][ii]
There is an added complication that the returned HTML needs to be modified by MobileFrontend, but hopefully that can be done in ApiVisualEditorEdit.
=== Use Cases
Beyond increasing the overall fluidity of the article "publishing moment," being able to dynamically update pages after an edit is published on mobile will enables us to offer people:
- New comment detection within the Reply Tool on mobile (T301929)
- Smoother experiences for publishing new comments and topics with DiscussionTools (T301839 + T301840)
//This section currently contains ideas that were "loosely sketched" during the Editing Team's 16 Feb 2022 team meeting.//
[x] Produce HTML with mobile transformations after saving
- (done in T266195)
[ ] Set up interactive elements (collapsible sections, TOC, page issues boxes) again after loading new contents
[ ] For the reply tool: Maybe add a `?expandall=1` hack so that we can just redirect to the #commentid and the browser will cope without any post-load JS?
- [ ] The way(s) in which this functionality could be implemented, and the trad eoffs associated with them, are documented in the `===Approaches` section above
- [ ] A decision is made about if/when the Editing Team will prioritize work on implementing one of the `===Approaches`