OpenCut-app / OpenCut-app/OpenCut

[PERF] Non-passive scroll listeners in timeline cause scroll jank

Open Beginner friendly
#729 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
89.8k
Forks
8.9k
PR merge metrics
No merged PRs in 30d

Description

Description

apps/web/src/hooks/timeline/use-scroll-sync.ts (lines 73-122) adds multiple scroll event listeners without the { passive: true } option.

Impact

Non-passive scroll listeners block the main thread during scrolling, causing jank especially on large timelines with many elements.

Fix

Add { passive: true } to scroll event listeners that don't call preventDefault().

Files

  • apps/web/src/hooks/timeline/use-scroll-sync.ts:73-122

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in apps/web/src/hooks/timeline/use-scroll-sync.ts at lines 73-122 and review each scroll listener for whether it calls preventDefault(). Add the passive option only to listeners that do not, then verify that timeline scrolling no longer exhibits the reported jank, including on timelines with many elements.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend, performance
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.