Advertisement
Guest User

Untitled

a guest
Mar 18th, 2019
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. /**
  2. * @desc: This snippet can be used to remove ads from the website.
  3. * @usage: Copy this snippet, paste this in your browser console.
  4. */
  5.  
  6. // This will extact all the links, which will be opening new tabs (mainly ads).
  7. var externalTabLinks = querySelectorAll("a[target='_blank']");
  8.  
  9. // All this links style we are setting to display as none and visiblity as hidden.
  10. externalTabLinks.forEach(el => {
  11. el.style.display = 'none';
  12. el.style.visiblity = 'hidden';
  13. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement