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
[BUG] This does not provide the correct parameters for addEventListener on new Chrome versions. "Unable to preventDefault inside passive event listener due to target being treated as passive"
#383
Open
douglasg14b opened this issue
Jun 6, 2021
· 1 comment
The default behavior is for window, document or body elements is: window.addEventListener("touchstart", func, {passive: true} ); unless {passive: false} is passed in explicitly. In this case the lib does not do this.
This means if anything down the road wants to preventDefault() the following exception will be thrown: Unable to preventDefault inside passive event listener due to target being treated as passive
The text was updated successfully, but these errors were encountered:
douglasg14b
changed the title
Just adding this Vue plugin (Not using the directive) breaks mobile tapping for some things like menus in other frameworks
This breaks some event handling in other frameworks "Unable to preventDefault inside passive event listener due to target being treated as passive"
Jun 6, 2021
douglasg14b
changed the title
This breaks some event handling in other frameworks "Unable to preventDefault inside passive event listener due to target being treated as passive"
This breaks some event handling in other frameworks on mobile "Unable to preventDefault inside passive event listener due to target being treated as passive"
Jun 6, 2021
douglasg14b
changed the title
This breaks some event handling in other frameworks on mobile "Unable to preventDefault inside passive event listener due to target being treated as passive"
This does not provide the correct parameters for addEventListener on new Chrome versions. "Unable to preventDefault inside passive event listener due to target being treated as passive"
Jun 6, 2021
HOWEVER, browser support is limited. Which means before this parameter can be used, support must first be checked, and if it does not exist, the old parameter should be used.
douglasg14b
changed the title
This does not provide the correct parameters for addEventListener on new Chrome versions. "Unable to preventDefault inside passive event listener due to target being treated as passive"
[BUG] This does not provide the correct parameters for addEventListener on new Chrome versions. "Unable to preventDefault inside passive event listener due to target being treated as passive"
Aug 21, 2022
The lib is not checking for passive support and providing the correct parameters if it exists. Google has a blog post on this change: (https://developers.google.com/web/updates/2017/01/scrolling-intervention):
The default behavior is for window, document or body elements is:
window.addEventListener("touchstart", func, {passive: true} );
unless{passive: false}
is passed in explicitly. In this case the lib does not do this.This means if anything down the road wants to preventDefault() the following exception will be thrown:
Unable to preventDefault inside passive event listener due to target being treated as passive
More Info:
Related: quasarframework/quasar#9577
The text was updated successfully, but these errors were encountered: