Page MenuHomePhabricator

Special:Uploads is built via webpack
Closed, ResolvedPublic5 Estimated Story Points

Description

mobile.special.uploads.scripts makes use of the mobile.gallery module. Nothing else makes use of this module, thus it makes sense to merge it into the mobile.special.uploads.scripts

Note: the module has dependencies on mobile.startup, mobile.gallery, mobile.scrollEndEventEmitter. Given a usage in category overlay, it is not trivial to merge in mobile.scrollEndEventEmitter so we will focus on mobile.gallery.

Acceptance criteria

  • The code in mobile.special.uploads.scripts is built via webpack
  • The code in mobile.startup has not grown in any substantial way. Consider introducing a new module mobile.special.scripts (to mirror mobile.special.styles) modules if this becomes a problem that can be shared across all special pages.
  • The module mobile.gallery has been removed (no need to worry about caching!).
  • The tests related to the feature (mobile.gallery) are run inside webpack
  • mobile.special.uploads.scripts has dependencies mobile.scrollEndEventEmitter and mobile.startup (ScrollEndEventEmitter is now in mobile.startup so only mobile.startup is needed as a dependency)

Sign off steps

  • Progress is updated.
  • Create task for porting mobile.special.mobileoptions.scripts, mobile.special.mobilediff.scripts and mobile.special.userlogin.scripts to webpack (no deps) - T213112

Event Timeline

Jdlrobson created this task.
Jdlrobson added a project: Web-Team-Backlog.
Jdlrobson updated the task description. (Show Details)

Change 484574 had a related patch set uploaded (by Jdlrobson; owner: Jdlrobson):
[mediawiki/extensions/MobileFrontend@master] Special:Uploads JavaScript built in webpack

https://gerrit.wikimedia.org/r/484574

Change 484574 merged by jenkins-bot:
[mediawiki/extensions/MobileFrontend@master] Special:Uploads JavaScript built in webpack

https://gerrit.wikimedia.org/r/484574

git checkout e1c212dbe1d583952b2de1eb7ee347108ba68d06 (this patch's commit)
curl -i 'http://localhost:8181/w/load.php?debug=false&lang=en&modules=mobile.startup&skin=minerva' | wc -c
90376

git checkout 9e99a7dff9d056d61ae50beffad16bdf3c4ebfaf (previous commit)
curl -i 'http://localhost:8181/w/load.php?debug=false&lang=en&modules=mobile.startup&skin=minerva' | wc -c
90376

Critical js is same size with this patch

nray removed nray as the assignee of this task.
nray updated the task description. (Show Details)
nray subscribed.