Advertisement
Snuggledash

8chan de-faggifier

Aug 1st, 2017
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name         8chan de-faggifier
  3. // @namespace    https://8ch.net
  4. // @version      0.1
  5. // @description  Removes 8chan formatting anti-features
  6. // @author       (You)
  7. // @match        http://8ch.net/*/index.html
  8. // @match        http://8ch.net/*/catalog.html
  9. // @match        http://8ch.net/*/res/*.html
  10. // @match        https://8ch.net/*/index.html
  11. // @match        https://8ch.net/*/catalog.html
  12. // @match        https://8ch.net/*/res/*.html
  13. // @grant        none
  14. // ==/UserScript==
  15.  
  16. (function() {
  17.     'use strict';
  18.     // remove fag quotes (interfere e.g. with IRC logs)
  19.     document.querySelectorAll('p.rquote').forEach(function(e, i, a) {
  20.         e.classList.remove('rquote');
  21.     });
  22.     // remove alt-right echo chambers
  23.     document.querySelectorAll('span.detected').forEach(function(e, i, a) {
  24.         let t = e.innerText;
  25.         t = t.replace(/^\(+/, '').replace(/\)+$/, '');
  26.         e.parentNode.replaceChild(document.createTextNode(t), e);
  27.     });
  28. })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement