Skip to content

Instantly share code, notes, and snippets.

@bengourley
Last active October 12, 2017 15:54
Show Gist options
  • Save bengourley/c84451d3413fc51aa21b4176e0618160 to your computer and use it in GitHub Desktop.
Save bengourley/c84451d3413fc51aa21b4176e0618160 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<title>callee.arguments test</title>
</head>
<body>
<script src="https://rawgit.com/stacktracejs/stackframe/master/dist/stackframe.js"></script>
<script src="https://rawgit.com/stacktracejs/stack-generator/master/dist/stack-generator.js"></script>
<script>
window.onerror = function () {
console.log(StackGenerator.backtrace())
}
var script = document.createElement('script')
script.src = '/bad.js'
window.document.body.appendChild(script)
</script>
</body>
</html>
function a () {
something_bad()
}
a()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment