Repository navigation
perf(web): share document parser bundles and skip covered snapshot reads - #920
Merged
Merged
Conversation
tt-a1i
marked this pull request as ready for review
November 13, 2026 16:32
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Web file attachment staging and Office preview ship separate worker bundles containing the same ExcelJS and Mammoth code. The Web store also queues a second snapshot read when events arrive during an outstanding read, even if the accepted response already contains those events.
Value
Against main
ffc9c624, the packaged Web assets shrink from 13,058,005 to 11,749,696 bytes (140 to 137 files). Localnpm pack --ignore-scriptsproduces a 4.87 MB tarball, down from 5.25 MB. In the overlapping-read regression the client makes one follow-up request after initialization instead of two. These measurements cover distribution size and a specific event ordering. End-user startup time was not measured.Approach
Validation
bun run checkandbun run test(2,476 Node passes, 8 skips, 1,652 UI passes). That run also contained the independent local test-runner changes.Impact
A smaller Git/npm distribution and fewer redundant reads under overlap. Prompt data formats, request authority, model-facing tools, and persisted data retain their contracts. The rebuild is included for source installations. The patch is reversible with a normal revert.