ticky

Jessica

@ticky

im in ur web site

(avatar by repoghost)


it's called WorseCohost

// ==UserScript==
// @name        WorseCohost
// @description Make Cohost slightly worse, to avoid things scrolling under you
// @match       *://*.cohost.org/*
// ==/UserScript==

const RealEventSource = EventSource;

window.EventSource = class EventSource extends RealEventSource {
    constructor(...args) {
        super(...args);
        super.close();
    }
}

It turns off the automatic server event streaming, because things moving as new posts load is driving me a bit nuts. It also means you won't see live updates to Place, and I believe notification counts will only load on a page load, but that's okay with me for now.


in reply to @ticky's post:

thanks for this!! it has been a bit jarring for posts to just Suddenly Appear. not that the feature isn’t good but, well, it could preserve my scroll position. programming is hard though so i’ll take this and at some point cohost will make it no longer necessary for me :3