Created
June 21, 2019 14:32
-
-
Save skibitsky/0e400f46ba68138fba8d2467d39679cf to your computer and use it in GitHub Desktop.
Antisaver userscript for Tampermonkey. It doesn't allow Safari to save page when ⌘ + S is pressed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Antisaver | |
// @version 0.1 | |
// @description Doesn't allow Safari to save page when ⌘ + S is pressed | |
// @include * | |
// ==/UserScript== | |
(function() { | |
'use strict'; | |
window.onkeydown = e => {if ((window.navigator.platform.match("Mac") ? e.metaKey : e.ctrlKey) && e.keyCode == 83) {e.preventDefault()}} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment