Skip to content

Instantly share code, notes, and snippets.

@nuxodin
Created December 8, 2016 15:13
Show Gist options
  • Star 11 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save nuxodin/1e5c7acc2abcb78a9d4cfe1d347d1cc6 to your computer and use it in GitHub Desktop.
Save nuxodin/1e5c7acc2abcb78a9d4cfe1d347d1cc6 to your computer and use it in GitHub Desktop.
Like to write to the console like this "console = xyz" instead of "console.log(xyz)" ?
!(function(){
var original = console;
Object.defineProperty(window, 'console', {
get:function(){
return original;
},
set:function(value){
original.log(value)
}
})
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment