Skip to content

Add only single event listener to body to handle touchmove events#3660

Open
kateinoigakukun wants to merge 1 commit intoreact-dnd:mainfrom
GoodNotes:yt/batch-touch-listener
Open

Add only single event listener to body to handle touchmove events#3660
kateinoigakukun wants to merge 1 commit intoreact-dnd:mainfrom
GoodNotes:yt/batch-touch-listener

Conversation

@kateinoigakukun
Copy link

connectDropTarget added a touchmove event listener to the body for each target node, which added performance overhead scaling with the number of target nodes. This commit changes it to add only one event listener to the body, which handles touchmove events for all target nodes.

`connectDropTarget` added a touchmove event listener to the body for
each target node, which added performance overhead scaling with the
number of target nodes. This commit changes it to add only one
event listener to the body, which handles touchmove events for all
target nodes.
@kateinoigakukun kateinoigakukun marked this pull request as ready for review April 7, 2025 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant