且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

动态加载的js函数不会出现在Firebug js调试器中

更新时间:2023-12-05 09:13:46

p>这是一个黑客,但是我通过在调试器中添加两次来阻止外部文件 js / page2.js 中的firebug。一旦在文件的顶部,另一次在功能的顶部。

It's a hack, but I got firebug to stop in the external file js/page2.js by adding the word debugger twice. Once at the top of the file and another time at the top of the function.

如果调试器字在任何一个地方只有一次,则firebug不会停止。

If the debugger word is there only once in either place, firebug does not stop.

debugger;
function test() {
    debugger;
    alert('Function Test()');
}