This continues the conversation in T209188#4836237
On mobile, VE uses the same base class as the source editor, EditorOverlayBase, and so they both use the toast’s showOnPageReload function to render the toast after the page has reloaded.
Given we only use this Toast on the editor and Special:MobileOptions let's rename src/mobile.startup/toast.js to showOnPageReload.js and deprecate and remove the Toast class to use mw.notify from now on. Following on from T209188 let's continue the conversation about the future of this code.
- showOnPageReload will be continue to be used in the 2 places it is currently being used (MobileOptions and the editor)
- Any existing usages of Toast and Toast.prototype.show will be replaced with mw.notify
Sign off steps
- Decide whether the resulting functionality showOnPageReload should be upstreamed to core and whether we can consolidate it with the wgPostEdit code mentioned in T209188#4836237