0

Unless there's a bug, Chrome devtools does not seem to want to pause on code within <script> tags for me. Hoping I didn't miss something.

Try this page: https://threejs.org/docs/scenes/material-browser.html#MeshPhysicalMaterial

Then in the HTML payload, in the inline script code, try putting a debugger in devtools.

For me, it never pauses.

For example, there is a line that starts with function guiMeshPhysicalMaterial, on which I put a debugger:

enter image description here

When I hit refresh, the script never pauses there.

Have I missed something? Or should I open a bug in Chrome's tracker?

trusktr
  • 44,284
  • 53
  • 191
  • 263
  • Does this answer your question? [Chrome javascript debugger breakpoints don't do anything?](https://stackoverflow.com/questions/11788081/chrome-javascript-debugger-breakpoints-dont-do-anything) – Ivar Jul 03 '22 at 08:48
  • @Ivar it doesn't seem to. – trusktr Jul 03 '22 at 09:08
  • `function` declaration is not a statement - due to hoisting - so you can't stop on it. – wOxxOm Jul 03 '22 at 12:28
  • 1
    You did not miss anything. It is a bug in Chrome. I created a bug report for this crbug.com/1342111 – Jecfish Jul 06 '22 at 03:05
  • @wOxxOm It doesn't pause on *any* line at all. Plus normally Chrome DevTools automatically puts the debugger (after clicking) at the *next* pausable line. – trusktr Jul 06 '22 at 18:03
  • @Ivar That does not answer the question, while this thread includes a link to a more useful Chrome bug report. Perhaps the other one should be closed in favor of this one instead, and this one should be closed too. – trusktr Jul 06 '22 at 18:07
  • I voted to close because it turned out to be a Chrome bug, and the link to the bug report is here in the question's comments. – trusktr Jul 06 '22 at 18:08

0 Answers0