Share

12 Responses to “How To Make Firebug's JavaScript Debugger Break Inside Dynamic JavaScript Using The 'debugger' Keyword (IE & Chrome Too)”

    10 Comments:
  1. jius0 says:

    this is quite interesting, I never saw the 'debugger' keyword before. It's not even a function… just a keyword. should be very helpful.

  2. Maciek says:

    Hi Artem,

    You should also know that the debugger keyword works for debugging code in IE if you have MS's script debugger tool installed.. It's not as awesome as Firebug, but it certainly is better than alert debugging and you can set breakpoints, watches, etc as well.

    Cheers

  3. chairface says:

    Is there a trick for getting the debugger keyword to work in Chrome? I already knew about it for Firebug, but Chrome seems to skip right over it. I've been setting breakpoints manually in Chrome when I can.

    • chairface,
      I don't think so. I'm running Chrome Beta 4.0.266.0 and my debugger triggers fine. You just have to open it before you refresh the page (Ctrl-Shift-J, then the Scripts tab).

      • chairface says:

        Hmm, that is very odd. I just tried it again, and it definitely isn't working. It may have something to do with being on a Mac, as I'm pretty sure their Mac support is still lagging behind Windows.

  4. Awesome. Thank you for writing about this.

  5. Rune says:

    The debugger keyword works in Opera Dragonfly as well.

  6. Smoking. It's actually faster to call the breakpoint line using debugger; when debugging code than setting it in Firebug which would otherwise require you to change the position of breakpoints to hit the 'same line' if you added another line of code. Suppose we could program logic into Firebug to let breakpoints follow code around but it would never be perfect.

  7. 2 Pings:
  8. Social comments and analytics for this post…

    This post was mentioned on Twitter by ArtemR: Just posted How To Make Firebug's JavaScript Debugger Break Inside Dynamic JavaScript Using The 'debugger' Keyword …: http://ping.fm/iAtWS...

  9. [...] How To Make Firebug's JavaScript Debugger Break Inside Dynamic … [...]

Leave a Reply

Connect with Facebook