Created
July 28, 2017 19:14
-
-
Save ujeenator/7d9d10dafec7385c4d85659754b6ebd0 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
Array.from(document.querySelectorAll('*')).forEach( | |
p => { | |
p.onblur = function(e) { | |
console.log('1') | |
e.preventDefault() | |
e.stopPropagation() | |
console.log('2') | |
return false | |
} | |
} | |
) | |
/* | |
var addEventListenerOriginal = DOMElement.prototype.addEventListener | |
DOMElement.prototype.addEventListener = function() { | |
if (arguments[0] === 'blur') { | |
return | |
} | |
return addEventListenerOriginal.apply(this, arguments) | |
} | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment