- JavaScript 69.4%
- Swift 20.6%
- HTML 4.1%
- CSS 3.8%
- Python 2.1%
| artwork | ||
| firefox | ||
| safari | ||
| scripts | ||
| tests | ||
| .gitignore | ||
| README.md | ||
Neuralyzer
Firefox and Safari web extensions that completely remove comments made by blocked Reddit users, including every reply nested beneath those comments, on Old Reddit and the current Reddit UI.
Neuralyzer is the memory-wiping device from Men in Black. We're wiping your (Reddit) memory of people and AI bots that you've blocked. Get it??
Why
I hate seeing any trace of comments made by blocked users. These are most likely AI bots I block, but also annoying users. I don't even want to know that the comment is there.
How
Old Reddit renders each comment as an outer .thing.comment element. Replies live inside that comment's .child element, so removing the outer comment removes its complete reply subtree as well.
Blocked comments expose a .collapsed-reason element whose text is blocked user. The adapter uses that marker to locate the enclosing .thing.comment and removes the entire node.
The new Reddit adapter recognizes the “Blocked User” badge in a shreddit-comment header and removes that comment, including its nested replies. It does not treat deleted authors, collapsed comments, or mentions of blocking in comment text as blocked users.
A MutationObserver watches for comments and badges inserted or updated after page load, such as dynamically expanded comment branches.
Toolbar toggle
Click the Neuralyzer toolbar icon to turn filtering ON or OFF for all Reddit tabs in that browser. The icon is grayed out when filtering is off and uses its normal appearance when on. Filtering starts enabled, and the setting is saved locally across browser restarts.
Turning filtering off restores removed comments and their replies in place without reloading the page. Turning it back on filters the current page immediately. On mobile Safari, use the Neuralyzer action in Safari's extensions menu.
Privacy
The extension does not make network requests, collect data, or transmit anything. It modifies Reddit pages locally and stores only the filtering on/off preference in extension storage.
Installation
Firefox package
Drag a signed .xpi package into a Firefox window, or load the source temporarily as described below.
Temporary installation in Firefox
- Open
about:debugging. - Choose This Firefox.
- Click Load Temporary Add-on….
- Select
firefox/manifest.json. - Visit an old Reddit comments page containing blocked users.
Temporary extensions disappear when Firefox restarts.
Safari (macOS, iPhone, and iPad)
Open safari/Neuralyzer/Neuralyzer.xcodeproj in Xcode. See Safari setup for signing, running, and enabling the extension.
Project layout
firefox/: installable Firefox extension source, including the original comment-removal logic and icons.safari/Neuralyzer/: Xcode project with macOS and iOS containing apps and Safari web extensions.safari/scripts/sync-web-extension.py: copies Firefox web assets into Safari and removes Firefox-specific manifest settings.
The displayed extension name is Neuralyzer. The Firefox ID remains area51@gioia.dev so existing Firefox installations retain their identity.
When changing comment-removal code, icons, or the manifest, edit firefox/, then run:
python3 safari/scripts/sync-web-extension.py
After changing the toolbar artwork, run swift scripts/generate-toolbar-icons.swift to regenerate the toolbar icons, then run the sync script above.
Commit the resulting Safari resources alongside the Firefox changes. The Xcode project uses these checked-in copies and builds without Firefox tooling or a resource generation step.
Both versions support Old Reddit and the current Reddit UI on old.reddit.com, www.reddit.com, and reddit.com. Neuralyzer does not redirect Reddit.
Regression tests
From the repository root, run python3 -m http.server 8765 --bind 127.0.0.1, then open http://127.0.0.1:8765/tests/ in a browser. Use ?platform=safari to test the bundled Safari resources. No package installation is needed.
The tests cover a sanitized new Reddit page structure, nested replies, unrelated comments, late-arriving badges and text, and Old Reddit behavior. The logged-in source capture is excluded from Git; the fixture contains no account details or remote assets.
Run node --test tests/background.test.cjs to check toolbar clicks, rapid toggles, and persisted state. The browser regression tests also cover comment restoration and repeated toggles.
Toolbar variants are solid silhouettes with transparent eye and mouth cutouts, without outlines: #111111 in light mode and #eee7db in dark mode. Safari may apply its own active accent color to the silhouette. The extension-list icons retain the original artwork.
The full-color iOS and macOS app icon master is artwork/app-icon.png. Run swift scripts/generate-app-icons.swift after replacing it to regenerate the app catalog and help-window icon.