Groups
Groups
Sign in
Groups
Groups
Firebug
Conversations
About
Send feedback
Help
Putting a breakpoint in dynamically generated JS does not always break?
28 views
Skip to first unread message
Dhruva Ray
unread,
May 13, 2013, 5:01:46 AM
5/13/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to fir...@googlegroups.com
Hi
See this sample file
<!DOCTYPE html>
<html>
<head>
<title></title>
<script>
var foo = Function("a","b","debugger;console.log(arguments);");
foo(1,2);
</script>
</head>
<body>
</body>
</html>
When the dynamically generated function foo is called, it does not break into the debugger. Am I missing something?
Regards,
Dhruva Ray
Dhruva Ray
unread,
May 13, 2013, 5:03:53 AM
5/13/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to fir...@googlegroups.com
Interestingly, If I split it up between 2 script blocks, the debugger breaks. Can someone please explain why?
<!DOCTYPE html>
<html>
<head>
<title></title>
<script>
var foo = Function("a","b","debugger;console.log(arguments);");
</script>
<script>
foo(1,2);
</script>
</head>
<body>
</body>
</html>
Regards,
Dhruva Ray
Sebastian Zartner
unread,
May 13, 2013, 6:26:12 AM
5/13/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to fir...@googlegroups.com
Thanks for the test cases.
Looks like this is related to
issue 312
.
Sebastian
Reply all
Reply to author
Forward
0 new messages