Skip to content

Instantly share code, notes, and snippets.

@akshatmittal
Created March 12, 2014 10:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save akshatmittal/9504158 to your computer and use it in GitHub Desktop.
Save akshatmittal/9504158 to your computer and use it in GitHub Desktop.
Console Disable JS
(function () {
var _z = console;
Object.defineProperty(window, "console", {
get: function () {
if (_z._commandLineAPI) {
throw undefined;
}
return _z;
},
set: function (val) {
_z = val;
}
});
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment