Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
disable context menu (right-click) on a webpage
// document can just as easily be an element
document.oncontextmenu = function() {
return false;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment