Catch execution-time JavaScript errors.