Skip to content

Instantly share code, notes, and snippets.

@richdownie
Created August 15, 2013 00:25
Show Gist options
  • Save richdownie/6237164 to your computer and use it in GitHub Desktop.
Save richdownie/6237164 to your computer and use it in GitHub Desktop.
<script>
//persist errors in jsErrors for ui testing
//<![CDATA[
window.jsErrors = [];
window.onerror = function(errorMessage, url, linenumber) {
window.jsErrors[window.jsErrors.length] = errorMessage + ' (' + url + ':' + linenumber + ')';
}
//]]>
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment