Created
March 23, 2016 05:16
-
-
Save joseeight/043d06f0c7d117031765 to your computer and use it in GitHub Desktop.
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
removeFacebookContent(); | |
window.addEventListener('scroll', removeFacebookContent); | |
function removeFacebookContent() { | |
var els = document.querySelectorAll('.shared-image, .video-embedded'); | |
for (var i = 0, currEl; | |
(currEl = els[i]); i++) { | |
currEl.innerHTML = "!!! Content was removed because this isn't Facebook !!!"; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
To avoid the error, you could just display = "none" or get fancy by adding a click to view link. I'll do that later with the Chrome extension.