Bug 200869 - Multiple scroll events during one requestAnimationFrame cycle
Summary: Multiple scroll events during one requestAnimationFrame cycle
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Scrolling (show other bugs)
Version: Safari Technology Preview
Hardware: Unspecified macOS 10.14
: P2 Major
Assignee: Nobody
Keywords: InRadar
Depends on:
Blocks: 202843
  Show dependency treegraph
Reported: 2019-08-18 09:46 PDT by alex
Modified: 2019-10-11 01:31 PDT (History)
5 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description alex 2019-08-18 09:46:23 PDT
Safari dispatches multiple scroll events during one requestAnimationFrame "cycle". But the scroll event should be limited to the rAF.

Steps to reproduce:

1. open page:
Demo: https://jsbin.com/joculitacu/edit?console,output

2. Scroll the page

What you see:
You see multiple outputs `bug.` inside of the console.

What I expect:
No output.

To me it is not entirely clear wether this is a bug with the scroll event or the rAF.
Comment 1 Radar WebKit Bug Importer 2019-08-18 11:36:32 PDT
Comment 2 alex 2019-08-19 01:30:34 PDT
Here you find an updated testcase:

The old one said "success." although it is a bug. Having multiple scroll events in one render cycle can lead to performance problems and layout thrashing. Additionally it is not standard complaint. This bug only occurs in Safari not in Chrome, FF or Edge.