Repository navigation
Conversation
This was referenced Oct 28, 2026
Collaborator
Author
|
Closing after an adversarial review pass (correctness + value lenses, judged per cluster). Closing. This is the same stale-controlled-prop pattern as #34961, applied to combined-diff sections. It adds three refs, render-time Monaco version and isDisposed checks, and a manual layout-effect |
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.
ELI5
Editing an editable section in the combined Changes view no longer rereads the whole draft just to confirm text that the editor already published.
What Changed
Capture the actual model, version and content when publishing a section draft. Keep the controlled wrapper prop stable only for that exact publication echo. Reuse the existing content-sync helper for an external reset that equals the held wrapper prop, and retire publication metadata with the editor.
This covers
DiffSectionItem→DiffSectionBody; #34961 covers the separateDiffViewerpath.Why
In a rendered 115,000-character combined-diff section, typing, Undo and Redo each performed two full editor reads. The same actions now perform one required publication read, while section text and dirty state still match the live model.
Linked Issue
Internal editor performance audit; no existing issue.
Visual Proof
N/A — no presentation or interaction change is intended. Before/after hidden Electron screenshots were inspected; the measured change is the avoided full-text equality read.
Testing
pnpm check:changed --maxWorkers=2: all 21 checks pass (117.2s).Review
Self-reviewed model/version/path ownership and cleanup. Existing platform, folder-workspace and remote routing are retained; native macOS/Windows, physical mobile and live SSH were not executed. Counts establish avoided work; CPU, latency and heap impact were not measured. One previous wrapper-prop string reference per mounted section remains until an external update, path change or teardown.
Agent skill upstream boundary