yoyobuae

Untitled

Dec 4th, 2020
598
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.74 KB | None | 0 0
  1. // ==UserScript==
  2. // @name Remove Literally Unplayable posts
  3. // @namespace https://www.reddit.com/r/factorio/
  4. // @match https://www.reddit.com/r/factorio/*
  5. // @match https://old.reddit.com/r/factorio/*
  6. // @version 1
  7. // @grant none
  8. // @require https://code.jquery.com/jquery-3.5.1.min.js
  9. // ==/UserScript==
  10. var patterns = [ 'Literally Unplayable', 'literally unplayable', 'Literally unplayable', 'literally Unplayable' ];
  11.  
  12. for (let pattern of patterns) {
  13. $("a.title:contains('" + pattern + "')").parentsUntil("div.sitetable").remove();
  14. }
  15. $(document).on("DOMNodeInserted", "div.Post", function () {
  16. for (let pattern of patterns) {
  17. $("h3:contains('" + pattern + "')").parentsUntil("div.Post").remove();
  18. }
  19. });
  20.  
Advertisement
Add Comment
Please, Sign In to add comment