You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 11, 2019. It is now read-only.
Thank you for awesome library!
I want to improve the performance of
window.onscroll
. must use theaddEventListener
passive option for that.There are several proposals in the options of how to specify, what do you think?
Pattern 1: Wrapped function
Pass a handler in object form, there is a pattern to specify the options.
I believe that this pattern is good.
Pattern 2: Capture like
onScrollCapturePassiveFooBar
)Pattern 3: Pass in component props
passive
options would be across all of the handler. (Example:onResize
)Side note: Polyfill sample of passive options
IE8 for the simple sample has been excluded.
The text was updated successfully, but these errors were encountered: