Repository navigation
Use a "normal" import statement to access the importPrintedAppearances function, in the src/core/worker.js file (PR 21858 follow-up) - #21923
Conversation
β¦es` function, in the `src/core/worker.js` file (PR 21858 follow-up) Currently this code is accessed with a dynamic import, which has the unfortunate side-effect of inflating the size of the *built* `pdf.worker.mjs` file a whole lot. Given the relatively small size of the `src/core/editor/print_appearances.js` file it really doesn't seem like an issue to just bundle that code unconditionally, and the existing pre-processor checks means that the `importPrintedAppearances` code will only be invoked in MOZCENTRAL builds. *NOTE:* This patch reduces the size of the `gulp mozcentral` bundle by `96` kilo-bytes, which I think is way too much to ignore.
Codecov Reportβ
All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #21923 +/- ##
==========================================
- Coverage 90.31% 90.30% -0.02%
==========================================
Files 269 269
Lines 67535 67534 -1
==========================================
- Hits 60992 60984 -8
- Misses 6543 6550 +7
Flags with carried forward coverage won't be shown. Click here to find out more. β View full report in Codecov by Harness. π New features to boost your workflow:
|
|
/botio browsertest |
From: Bot.io (Windows)ReceivedCommand cmd_browsertest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/8302166e6abfc1e/output.txt |
From: Bot.io (Linux m4)ReceivedCommand cmd_browsertest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.241.84.105:8877/53f9e41baf5d108/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.241.84.105:8877/53f9e41baf5d108/output.txt Total script time: 18.97 mins
|
From: Bot.io (Windows)SuccessFull output at http://54.193.163.58:8877/8302166e6abfc1e/output.txt Total script time: 23.91 mins
|
Currently this code is accessed with a dynamic import, which has the unfortunate side-effect of inflating the size of the built
pdf.worker.mjsfile a whole lot.Given the relatively small size of the
src/core/editor/print_appearances.jsfile it really doesn't seem like an issue to just bundle that code unconditionally, and the existing pre-processor checks means that theimportPrintedAppearancescode will only be invoked in MOZCENTRAL builds.NOTE: This patch reduces the size of the
gulp mozcentralbundle by96kilo-bytes, which I think is way too much to ignore.