Skip to content

Commit e2fc53e

Browse files
authored
Create fuckdevtools.js
1 parent eb0b428 commit e2fc53e

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

fuckdevtools.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
/*
2+
FuckDevTools.Js
3+
By @ghalbeyou on GitHub
4+
https://github.com/GhalbeYou
5+
---------------------------------------
6+
This is a simple script that will disable the developer tools in the browser.
7+
*/
8+
9+
document.onkeydown = function(event) {
10+
if (event.keyCode == 123) {
11+
event.preventDefault();
12+
alert("Devtools?");
13+
location.replace("about:blank");
14+
15+
}
16+
// if the user pressed the Control + Shift + I key
17+
else if (event.ctrlKey && event.shiftKey && event.keyCode == 73) {
18+
event.preventDefault();
19+
alert("Devtools?");
20+
location.replace("about:blank");
21+
}
22+
}
23+
document.oncontextmenu = function() {
24+
event.preventDefault();
25+
alert("Devtools?");
26+
}

0 commit comments

Comments
 (0)