downshift-js/downshift

Consider using passive event listeners

オープン

#1,650 opened on 2025/05/23

 (2 件のコメント) (0 件のリアクション) (0 人の担当者)JavaScript (980 件のフォーク)batch import
help wantedneeds investigation

Repository metrics

Stars
 (11,761 個のスター)
PR merge metrics
 (PR metrics pending)

説明

When rendering a Downshift component in Chrome, I see this message logged in the console:

[Violation] Added non-passive event listener to a scroll-blocking 'touchstart' event. Consider marking event handler as 'passive' to make the page more responsive. See https://www.chromestatus.com/feature/5745543795965952

Chrome developer tools indicates that these listeners are not passive: https://github.com/downshift-js/downshift/blob/master/src/hooks/utils.js#L421-L425

Would it be possible to make these listeners passive without affecting functionality?

コントリビューターガイド