Skip to content

Rapid Diffs ViewComponents foundation

What does this MR do and why?

Implements Create ViewComponents (HAML) for Rapid Diffs (#451789 - closed).

This MR adds foundational ViewComponents for Rapid Diffs:

  1. DiffFileComponent
  2. DiffFileHeaderComponent

This includes very basic logic for the components and basic styling. Please not the the actual viewer part is reused right now. It should be rewritten as ViewComponents in future iterations.

This MR also renders these components on the commit view and merge request diffs tab.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

image

How to set up and validate locally

  1. Enable rapid_diffs feature flag
  2. Open any commit view
  3. Add ?rapid_diffs=true to the URL and load that URL
  4. You should see diffs rendered using the new ViewComponents
Edited by Stanislav Lashmanov

Merge request reports