Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save ThisIsMissEm/164370 to your computer and use it in GitHub Desktop.
Save ThisIsMissEm/164370 to your computer and use it in GitHub Desktop.
var scripts = document.getElementsByTagName('script');
for(var i=0; i<scripts.length; ++i) {
scripts[i].parentNode.removeChild(scripts[i]);
// Browsers won't garbage collect this object.
// So castrate it to avoid a major memory leak.
console.log('-----------------');
for (var prop in scripts[i]) {
console.log(prop, " : ", scripts[i][prop]);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment