Spike: Rendering MR diffs from diff blobs instead of line-by-line json structures
Proposal
In the context of the Performance Round TablesCode Review and following the experience of the Feedback issue: Micro Code Review Frontend PoC (#389282 - closed), the idea came up of rendering the diff from an entire blob rather than metadata-annotated line by line json structure.
In essence this is what we're talking about:
Before(now) | Proposed |
---|---|
![]() |
![]() |
Known challenges / open questions
Things we currently don't have an answer for:
-
How big are the performance gains?
- In terms of backend response times? (time to first byte but also downloading times in slow networks)
- In terms of frontend performance? (memory usage, LCP, TBT, ...)
- How can we match Notes/Comments to Diff Lines?
- What features are affected by not having the raw lines content in our Vue app? (eg: Suggestions would need a way to grasp the raw lines whether from the DOM or from the server).
Expected outcome
These questions can be answered by iterating on the PoC codebase but we are aiming to get a good understanding of how this could be done within the GitLab MR app, too.
Definition of done:
- a list of tasks to implement a viable migration path
- a comment reporting the findings for each one of the questions above in Known Challenges section.