Skip to content

Instantly share code, notes, and snippets.

@nuxodin
Created December 8, 2016 15:13
Show Gist options
  • 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