Upgrade to Pro — share decks privately, control downloads, hide ads and more …

JavaScript Stack Traces: The good, the bad, and...

JavaScript Stack Traces: The good, the bad, and the ugly

Error monitoring in the browser is a thorny problem. On the one hand window.onerror will at least notify you when something goes wrong, on the other, it won't give you enough information to actually debug the problem! Notably absent in many cases is the stack trace. In this talk, I’ll explain how with a little bit of work, it's possible to get stack traces that are reasonably complete in all browsers, even IE.

First presented at the Forward3 Web Technology Summit on July 29th 2015.

James Smith

July 29, 2015
Tweet

More Decks by James Smith

Other Decks in Programming

Transcript

  1. JAVASCRIPT STACK TRACES THE GOOD, THE BAD, AND THE UGLY

    JAMES SMITH (@LOOPJ) - CO-FOUNDER @ BUGSNAG
  2. WTF IS A STACK TRACE? AKA “What code caused this

    crash?” “The sequence of functions called so far in a program”
  3. WHY DO I NEED A STACK TRACE? "Generally, if you

    can’t reproduce a bug, it’s almost impossible to fix" - Michael Scott
  4. CAN WE ALWAYS GET A STACK TRACE? YES!* *But browser

    differences make things difficult
  5. THAT SOUNDS LIKE A LOT OF WORK YOU CAN LET

    US HANDLE EVERYTHING FOR YOU! https://bugsnag.com