Reputation: 12864
I am starting out with Firebug.
I have a JS file that has some JQuery in it.
how do I debug that code when the HTML page rendered does not have any javascript just ref to my file.
thanks Malcolm
Upvotes: 8
Views: 6154
Reputation: 36586
In the new firebug you need to click on the file list to get access to external js files. It is no longer in the "Script Tab". Once you've changed to the js file you want to set the breakpoint in you just need to click the line number on the left and reload the page.
alt text http://rival-studios.com/Portals/0/so-firebug.gif
Upvotes: 2
Reputation: 21695
You can add "debugger;" string before the line which you want to debug.
This will invoke Firebug's JS debugger.
Upvotes: 3
Reputation: 5080
Open Firebug. Click on "Script" then choose your external JS-File from the dropdown menu.
Upvotes: 4
Reputation: 3205
If you go to the script tab there'll be a little drop down box that will you let you select any scripts linked to in the page. Won't help you much if they're minified though...
Upvotes: 6