"Added non-passive event listener to a scroll-blocking" Error


(Jose) #1

Hello, I’ve added an iframe in my wordpress site. The iframe contains an html file made in hype. When I inspect the page in Chrome I see the error [Violation] Added non-passive event listener to a scroll-blocking event. Consider marking event handler as ‘passive’ to make the page more responsive. See

See also screenshot.

How can I solve this?

Thanks


(Jose) #2

The screenshot…


(Jonathan Deutsch) #3

That’s interesting. Do you mind sending the URL of the site and a zip of your .hype document? Are you using the wordpress plugin?

You can probably get around it by unchecking Use Touch Events in the Document Inspector.


#4

I get this when Hype file testing in Chrome:

20

17

No problem for me, but maybe it helps to know what’s going on.


(Jose) #5

Solved unchecking touch events!!

Thanks


(Jonathan Deutsch) #6

@Djon and @JoseC, still any chance you could attach zips of your .hype documents causing these? They probably aren’t much of an issue (Hype does need to do certain things!) but may be items I can improve. I’m a little surprised it is complaining about touchstart since this should only be applied on mobile.

Is this macOS 10.13.3 with the latest Chrome (65.0.3325.162) or a different configuration? Thanks!


(Jose) #7

Of course, here it goes.

Good luck and thanks again.


(Jonathan Deutsch) #8

I don’t think the attachment went through - if it is too big for the forums feel free to use a dropbox/wetransfer link or email to support@tumult.com. Thanks!


(Jose) #9

Done!


(Jonathan Deutsch) #10

Got it, thanks! I’m still not able to see any of the violation messages; is there any other trick than opening your document in Hype and previewing direct to Chrome? Or does this only happen when embedded as an iframe on your wordpress site?

Have you tried with all extensions disabled (like could be done in incognito mode)?

Is this macOS 10.13.3 with the latest Chrome (65.0.3325.162) or a different configuration? Thanks!


#12

Try looking at verbose logging in the console?

I wouldn’t worry about these message as it’s just Chrome warning you about timings and what not. Generally “Verbose” should be switched off. Maybe it got ticked at some point. Also, these messages are on most sites not just Hype document embedded ones.


(Jonathan Deutsch) #13

I see it now with a repro case sent in via email, thanks!

(I’m more curious not that it is probably bad - we might even be doing the right thing, but I’m surprised to see messages about touchstart on Desktop so I want to investigate.)


(Jonathan Deutsch) #14

Thanks, I can see this violation warning now and looked into it.

For the most part it is harmless (especially on Chrome where touchstart isn’t used anyhow), but if I were to make some changes to Hype it could increase scroll performance on mobile devices.