• Merry Christmas and a Happy New Year from all of us at Irish Gamers Community

    Stay safe and have a great holiday and see you all in 2021 for more!

Dermot

Administrator
Staff member
Messages
471
Age
42
Location
Ireland
This post will show you how to remove promoted posts from showing on Reddit.

You will need a Userscript Plugin/Addon/Extension for your Web Browser, Some are linked below for your convenience.

Chrome based Browsers: TamperMonkey ViolentMonkey
Firefox based Browsers: GreaseMonkey TamperMonkey ViolentMonkey

When you install these on your browser, you will get the chance to add your own Userscripts.

Add the following Userscript to remove the promoted posts on Reddit.

Userscript to remove Reddit Promoted Posts:
// ==UserScript==
// @name         Kill Promoted Reddit Posts
// @namespace    http://reddit.com/
// @version      1.0
// @description  Remove Promoted Reddit Posts
// @author       D
// @match        https://www.reddit.com/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    const promotedPosts = document.getElementsByClassName('promotedlink');
    let totalPosts = 0;

    const hidePromotedPosts = () => {
        if (promotedPosts.length === totalPosts) return;
        totalPosts = promotedPosts.length;
        Array.from(promotedPosts).forEach((post) => {
            post.style.display = 'none';
        });
    };

    hidePromotedPosts();
    document.body.addEventListener('DOMNodeInserted', hidePromotedPosts);
})();

When added, Make sure to go to File -> Save to save the script and then just refresh Reddit page to enable script.

Any questions, Ask below.
 

Users who are viewing this thread

Videos

Reviews

 Past Streams

Like Us

Top