Skip to content

Instantly share code, notes, and snippets.

@textgoeshere
Created July 13, 2011 09:45
Show Gist options
  • Save textgoeshere/1080005 to your computer and use it in GitHub Desktop.
Save textgoeshere/1080005 to your computer and use it in GitHub Desktop.
console killer
if (typeof window.console == "undefined") {
if (!window.console || !console.firebug)
{
var names = ["log", "debug", "info", "warn", "error", "assert", "dir", "dirxml",
"group", "groupEnd", "time", "timeEnd", "count", "trace", "profile", "profileEnd"];
window.console = {};
for (var i = 0; i < names.length; ++i)
window.console[names[i]] = function() {}
}
}
@textgoeshere
Copy link
Author

hmm should add groupCollapsed in names

@jbpros
Copy link

jbpros commented Jul 13, 2011

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment