1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-10-23 17:18:51 +02:00
phorge-phorge/webroot/rsrc/js/application/diff
epriestley c666cb9f0b Reduce the frequency of DOM scans to rebuild inlines when scrolling revisions
Summary:
Ref T13513. See PHI1734, which raises a concern about the performance of large revisions near the 100-change threshold.

Currently, `getInlines()` is called whenever the scroll position transitions between two changesets, and it performs a relatively complicated DOM scan to lift inlines out of the document.

This shows up as taking a small but nontrivial amount of time in Firefox profiles and should be safely memoizable.

Test Plan:
  - Under Firefox profiling, scrolled through a large revision.
  - Before change: `getInlines()` appeared as the highest-cost thing we're explicitly doing on profiles.
  - After change: `getInlines()` was no longer meaningfully represented on profiles.
  - Created inlines, edited inlines, etc. Didn't identify any broken behavior.

Maniphest Tasks: T13513

Differential Revision: https://secure.phabricator.com/D21261
2020-05-15 09:37:41 -07:00
..
DiffChangeset.js Reduce the frequency of DOM scans to rebuild inlines when scrolling revisions 2020-05-15 09:37:41 -07:00
DiffChangesetList.js Improve offset/range inline behavior for rich diffs and unified diffs 2020-05-14 16:02:32 -07:00
DiffInline.js Give selected inline comments are more obvious selected state 2020-05-14 14:35:55 -07:00
DiffPathView.js Make "hidden" changesets sticky, and show hidden state in the filetree 2020-04-22 16:12:42 -07:00
DiffTreeView.js Mark "low importance" and "owned" changes in the filetree 2020-04-22 11:22:34 -07:00