Answer the question
In order to leave comments, you need to log in
How to connect your JS script to a React project?
There is such a simple ContextMenuOff.js file that should simply disable the context menu on the site.
'use strict'
document.oncontextmenu = ev => {
return false;
}
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<script src="./src/Scripts/ContextMenuOff.js"></script>
</body>
Answer the question
In order to leave comments, you need to log in
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<script>
document.oncontextmenu = ev => {
return false;
}
</script>
</body>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question