This could be useful to have available in all templates, so that we can detect JS errors on any page through Selenium.

Also, another reason to put this in a JS var (attribute on `window`) instead of on the `body`, is that I think with the current approach if an error happens before the DOM has loaded, it will be discarded (since there won't yet be any match for `body`).

It could then be put at the top of the JS in base.html. Thoughts, @bcipolli?

This won't interfere in the propagation of the error, as long as you don't return "true" from this function. It just adds a bit of logging that's accessible to Selenium (and to any in-page scripts, such as our "Feedback Form", which could include any JS errors in the report it sends us).