201310.03

Debugging Firefox addons

As you all know, I'm building a Turtl, a browser extension for client-side encrypted note/file storage.

Well once in a while the I need to debug the release version. There are docs scattered around detailing how to do this, but as usual with this type of thing you really need to do some digging.

By default, Firefox's Browser Console only logs error events. You can change this to log any and all console.log() calls from your addon (and any other addon) by doing this:

  1. Go to about:config
  2. Search for the key extensions.sdk.console.logLevel
  3. If it exists, set it to "info", otherwise add a new string with the key extensions.sdk.console.logLevel and the value "info"

Boom, all your addon's log calls now show up in the browser console.