Rendering huge pull requests in the GitHub Copilot app
GitHub engineers rebuilt the Copilot app pull request view to handle massive diffs efficiently. The system now renders a test case with 2,200 files and over one million changed lines smoothly. By virtualizing code rows and dynamically measuring comment heights, the interface maintains performance despite complex markdown content and inline review conversations.

GitHub engineers rebuilt the pull‑request view inside the Copilot app so it can render an extreme change set consisting of 2,200 files, more than a million changed lines and over 400 inline review comments without slowing down. The new design virtualizes code rows, keeping only a few dozen DOM nodes alive at any time, and adds a second geometry layer that measures comment blocks lazily. By separating deterministic code height from dynamic comment height, the interface stays responsive even when markdown, expandable sections or images alter the layout after the initial paint. Large diffs are common in massive refactors or migrations, and reviewers need a fast, smooth experience to avoid bottlenecks. The virtualization approach prevents the browser from being overwhelmed by a million DOM elements, while the dynamic block strategy eliminates the jarring scroll jumps that happen when comment heights are mis‑estimated. Maintaining performance at this scale helps teams ship complex changes with less risk and keeps the review conversation usable. It remains uncertain how the solution will behave on pull requests that exceed the tested size or on browsers with different rendering engines. The team has not disclosed whether the lazy measurement technique introduces any latency for users with very slow network connections. Further observation is needed to confirm that the dual‑geometry model scales uniformly across all real‑world scenarios.