Filtering results for:
David Cramer

Why Johnny Can't Collect Browser Errors

If an error occurs on your website, and you weren’t there to log it, did it happen?

Well, yes. It did. But even if you decided to start logging such errors, you’d learn something really quickly: logging JavaScript errors is hard.

In this talk from JSConf Uruguay, Sentry VP of Engineering Ben Vinegar discusses the state of client-side JavaScript error logging in 2016, covering topics like:

  • window.onerror – how it works, in what browsers, and what happens when it doesn’t (work)
  • why you still have to use try/catch in some places
  • the Error object
  • extracting and normalizing stack traces (because they’re different in every browser, ouch!)
  • why NodeJS has it easy!

At the end of this talk, you’ll have all the information you need to get started logging your own client-side errors. And even if you use a 3rd-party service/client library to do it for you instead, you’ll have a better handle on how those tools work under the hood.

View site
Date
People
Tags