https://github.com/ludios/expand-everything
A userscript to click "show more" links to expand all the text on a page, without slowing things down too much
https://github.com/ludios/expand-everything
annoyance chromium javascript userscript web
Last synced: 6 months ago
JSON representation
A userscript to click "show more" links to expand all the text on a page, without slowing things down too much
- Host: GitHub
- URL: https://github.com/ludios/expand-everything
- Owner: ludios
- License: agpl-3.0
- Created: 2023-01-03T15:12:51.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2025-05-02T06:44:41.000Z (9 months ago)
- Last Synced: 2025-05-19T22:11:30.631Z (8 months ago)
- Topics: annoyance, chromium, javascript, userscript, web
- Language: JavaScript
- Homepage:
- Size: 229 KB
- Stars: 96
- Watchers: 4
- Forks: 3
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Expand Everything
*Load more!*, *show more!*, *read more!* - these are the cursed buttons that
website owners make you click before you can see all the information that you
came to read. Reviews and comments deemed "too long"; YouTube video descriptions
that are hidden. Expand Everything fixes this by clicking them for you.
This is ideally suited for use cases where you plan to read, print, copy, or
archive (e.g. [SingleFile](https://github.com/gildas-lormeau/SingleFile)) the
entire page.
Demo.
Efforts are made to avoid slowing things down after the initial load. We use
`MutationObserver` and `querySelectorAll` to watch for the elements that
we need to automatically click, but crucially:
1) The MutationObserver is disconnected after e.g. 200 mutations to avoid
slowing things down. The "stop the observer" count is different for
each website and you can try adjusting them to your liking.
2) The MutationObserver is reinstalled after an SPA navigation (because
there might be new elements to click on).
When available, we use [Navigation API](https://caniuse.com/mdn-api_navigation)
to watch for location changes; otherwise, we use `setInterval(..., 1000)`,
but stop polling when the page is not visible.
## Install
This is distributed as a userscript, so you need a browser extension that runs userscripts.
[Violentmonkey](https://violentmonkey.github.io/) can be installed in Firefox and Chromium-based browsers. [Userscripts](https://apps.apple.com/us/app/userscripts/id1463298887) works in Safari.
Then, visit [expand.user.js](https://raw.githubusercontent.com/ludios/expand-everything/master/expand.user.js) and _Confirm installation_.
(Alternatively, create a new script and paste in the entire expand.user.js source.)
## Supported sites
- https://github.com/ ("Load more" all the issue comments, expand minimized and similar comments, expand outdated review comments)
- https://gist.github.com/ (load all comments)
- https://www.youtube.com/ (expand video descriptions and comments, load more comments)
- https://www.google.com/ (in reviews for a business, expand text)
- https://x.com/ & https://twitter.com/ ("show more" on long tweets; in threads, show replies to replies, show "probable spam")
- https://stackoverflow.com/ and all other Stack Exchange sites (show all comments)
- https://\*.substack.com/ (dismiss subscribe overlay, expand comment text)
- https://substack.com/ (expand comment text on notes)
- https://www.goodreads.com/ (expand book review text)
- https://old.reddit.com/ (expand comments below threshold, expand deleted comments)
- For "load more comments", you'll need [Reddit Enhancement Suite](https://github.com/honestbleeps/Reddit-Enhancement-Suite) and its "Never Ending Comments", "Load Child Comments" options.
- https://news.ycombinator.com/ (expand collapsed comments)
- https://www.quora.com/ (expand answer text)
- https://www.nytimes.com/ (expand mini articles on live coverage pages)
- https://www.bloomberg.com/ (on author pages, load all story headlines)
- https://www.imdb.com/ (expand film review text, load more reviews)
- https://www.criticker.com/ (expand minireview text)
- https://\*.linkedin.com/ (expand text in profiles, comments on posts)
- https://www.lesswrong.com/ (expand collapsed comments)
- https://tvtropes.org/ (open all folders)
- https://cohost.org/ (expand posts on actual post pages)
- https://nextdoor.com/ (expand posts and comments)
- https://store.steampowered.com/ (expand review text, early access information)
- https://www.patreon.com/ (expand post bodies)
- https://www.hwinfo.com/forum/ (expand quote blocks)
- https://mastodon.social/ and https://social.pixie.town/ (expand toots hidden behind a spoiler)
For test pages, see the "Test page:" comments in expand.user.js.
## Demo
The video description and comment replies are expanded automatically.