简体   繁体   English

如何删除导致Chrome挂起的断点

[英]How to remove breakpoints causing Chrome to hang

Is it possible to delete all breakpoints without opening Chrome devtools? 是否可以在打开Chrome devtools的情况下删除所有断点?

I have a breakpoint set in a large obfuscated javascript file that cause the current tab to hang if I have devtools open while the page loads. 如果在页面加载时打开devtools,则在一个模糊的大型javascript文件中设置了一个断点,导致当前选项卡挂起。 I have no problems if i let the page load, and then open the devtools, but then the script is not visible in the sources and network panels. 如果让页面加载,然后打开devtools,我没有问题,但是脚本在源代码和网络面板中不可见。

I have attempted to disable breakpoints by immediately activating the "Deactivate all breakpoints" button when the page loads, but the breakpoint still triggers causing the tab to hang. 我试图通过在页面加载时立即激活“停用所有断点”按钮来禁用断点,但是断点仍然会触发,导致选项卡挂起。

Update: This problem only happens when the sources panel in the devtools is open during page load. 更新:仅在页面加载期间打开devtools中的面板时,才会发生此问题。

As @Andrey points out, when the dev tools are closed Chrome will never break on a breakpoint. 正如@Andrey指出的那样,关闭开发工具后,Chrome将永远不会在断点处中断。

You can disable breakpoints using Ctrl + F8 , hitting F8 afterwards will continue from the current breakpoint. 您可以使用Ctrl + F8禁用断点,然后再按F8键将从当前断点继续。

禁用断点-Chrome

You can also view a summary of all active BP's in the right of dev tools. 您还可以在开发工具的右侧查看所有活动BP的摘要。

断点摘要-Chrome

Update: A last resort option is to clear the dev tools settings as follows. 更新: 不得已的方法是按如下所示清除开发工具设置。 Note this will clear reset any customized settings you have... 请注意,这将清除重设您拥有的所有自定义设置...

Settings > Restore defaults and reload Settings > Restore defaults and reload

开发人员工具重置-Chrome

我终于设法通过简单地退出chrome并再次重新登录来重置devtools,包括所有断点。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM