Chrome开发人员工具会在没有设置断点的地方不断崩溃 [英] Chrome Developer Tools keeps breaking where no breakpoints are set
问题描述
使用Chrome开发者工具调试JavaScript代码时,调试器会在未设置断点的代码上暂停.我没有启用Pause on exceptions
功能,并且肯定没有设置断点(请参见附图).
When debugging JavaScript code using Chrome Developer Tools the debugger pauses on code where breakpoints are not set. I don't have the Pause on exceptions
feature enabled, and there definitely are not breakpoints set (see attached image).
我问了类似的问题之前很有帮助,但并不能完全解决此问题(以前我启用了Pause on exceptions
).在下面的示例中,我将最小版本的kendo.all.min.js
替换为最小版本,这使我可以看到脚本执行被暂停的位置,但是我不知道为什么它被暂停. jquery.min.js
也经常发生这种情况.
I asked a similar question before which was helpful but didn't quite solve this issue (previously I had the Pause on exceptions
enabled). In the example below I swapped out the minified version of kendo.all.min.js
for the unminified version, which allows me to see where the script execution is being paused, but I don't know why it is being paused. This happens a lot with jquery.min.js
too.
推荐答案
我通过单击设置"部分中的恢复默认值并重新加载"按钮解决了断点问题. (如果需要)找到按钮:在Developer Tools中,单击右上角的三个垂直点,然后选择"Settings F1";按钮恢复默认设置并重新加载"位于右下角.
另请注意,它确实可以恢复默认设置-您将丢失所有先前保存的断点,并且在开发人员工具中打开的所有文件都将被关闭.
我从以下位置获得了此解决方案: Chrome JavaScript调试器断点不起作用什么?
I fixed my breakpoints problem by clicking the "Restore defaults and reload" button located in the "Settings" section. (If needed) to find the button: In Developer Tools click the top right three vertical dots and select "Settings F1"; the button "Restore defaults and reload" is at the bottom right.
Also note that it really restores defaults - you lose all previously saved breakpoints and any files you have open in Developer Tools will be closed.
I got this solution from: Chrome javascript debugger breakpoints don't do anything?
这篇关于Chrome开发人员工具会在没有设置断点的地方不断崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!