Issue metadata
Sign in to add a comment
|
Updated to Chrome v65 and started getting this error: Expected onClick listener to be a function, instead got type string
Reported by
bruce.w...@l2inc.com,
Mar 8 2018
|
||||||||||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.146 Safari/537.36 Steps to reproduce the problem: 1. Open a React app with minified code (version >= 15.0.0) 2. onClick listener errors out and all onClick events on the page do nothing) What is the expected behavior? There should be no strings being passed into onClick event listener callbacks but instead functions, thereby not giving an error. What went wrong? minified React code claims there is a string being passed into an onClick listener but our code contains none of that behavior. The error prevents any button/dropdown from working properly/ Did this work before? Yes Chrome 64 Chrome version: 65.0.3325.146 Channel: stable OS Version: OS X 10.13.3 Flash Version:
,
Mar 9 2018
,
Mar 9 2018
Hi! Unfortunately we can't send a testpage because the software is proprietary, however this error is the full extend of our knowledge of the bug. The webpage that this bug occurs on has simple bootstrap buttons, clickable <div>'s, and react-router-bootstrap links. We tried removing every onClick listener and button from our page but the error still says a string is being passed into an onClick listener. We think there is a bug with Chrome v65's Javascript minification changes because our codebase works on localhost but this bug appears after the code is compiled and minified.
,
Mar 9 2018
Thank you for providing more feedback. Adding the requester to the cc list. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Mar 10 2018
If this is a React-specific issue, please contact React team first, unless you can create a minimal reproduction case which is not proprietary.
,
Mar 20 2018
Bruce did you get this figured out? It most certainly isn't an issue in Chrome. Does it reproduce in Firefox as well?
,
Mar 20 2018
Hi! Yes I figured out the bug was a minification error however I think the fault laid with the react-bootstrap library we used. We removed their React components for rendering tooltips and routing buttons and the bug went away. I posted a thread on Stackoverflow and other people seems to get this error and the common denominator is incompatibility between certain React builds and Chrome v65 minification. https://stackoverflow.com/questions/49182801/updated-to-chrome-v65-and-started-getting-this-error-expected-onclick-listener/49200665#49200665
,
Mar 20 2018
Thank you for providing more feedback. Adding the requester to the cc list. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Mar 22 2018
bruce.wang@ Thanks for the issue. As per comment #7, can you please confirm if this issue can be closed ? Thanks..
,
Mar 22 2018
Yes, it can be closed.
,
Mar 22 2018
Closing as per 10.
,
Mar 24 2018
The NextAction date has arrived: 2018-03-24 |
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by pbomm...@chromium.org
, Mar 9 2018